testutils

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateDefaultEndpoint

func CreateDefaultEndpoint() *corev1.Endpoints

func CreateDefaultExternalHostPaths

func CreateDefaultExternalHostPaths() []esov1alpha1.ExternalServiceHostPath

func CreateDefaultExternalService

func CreateDefaultExternalService() *esov1alpha1.ExternalService

func CreateDefaultTestProbe

func CreateDefaultTestProbe() corev1.Probe

func CreateExternalService

func CreateExternalService(name string, namespace string, ips []string, port int, hosts []esov1alpha1.ExternalServiceHostPath) *esov1alpha1.ExternalService

func CreateTestProbe

func CreateTestProbe(delay int32, timeout int32, period int32, success int32, failure int32, scheme corev1.URIScheme, port int32, path string) corev1.Probe

func ExpectEndpointOwnerReference

func ExpectEndpointOwnerReference(actual *corev1.Endpoints, instance *esov1alpha1.ExternalService, t *testing.T)

func ExpectEndpointWithNameAndNamespace

func ExpectEndpointWithNameAndNamespace(actual *corev1.Endpoints, name string, namespace string, t *testing.T)

func ExpectEqInt

func ExpectEqInt(actual int32, expected int32, t *testing.T)

func ExpectEqStr

func ExpectEqStr(actual string, expected string, t *testing.T)

func ExpectEqualEndpoints

func ExpectEqualEndpoints(actual, expected corev1.Endpoints, t *testing.T)

func ExpectFalse

func ExpectFalse(result bool, t *testing.T)

func ExpectIngressOwnerReference

func ExpectIngressOwnerReference(actual *extv1.Ingress, instance *esov1alpha1.ExternalService, t *testing.T)

func ExpectIngressWithNameAndNamespace

func ExpectIngressWithNameAndNamespace(actual *extv1.Ingress, name string, namespace string, t *testing.T)

func ExpectNoErrorsAndRequeue

func ExpectNoErrorsAndRequeue(res reconcile.Result, err error, t *testing.T)

func ExpectServiceOwnerReference

func ExpectServiceOwnerReference(actual *corev1.Service, instance *esov1alpha1.ExternalService, t *testing.T)

func ExpectServiceType

func ExpectServiceType(actual corev1.ServiceType, expected corev1.ServiceType, t *testing.T)

func ExpectServiceWithNameAndNamespace

func ExpectServiceWithNameAndNamespace(actual *corev1.Service, name string, namespace string, t *testing.T)

func ExpectTrue

func ExpectTrue(result bool, t *testing.T)

func InitFakeClient

func InitFakeClient(objs ...runtime.Object) client.Client

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL