Documentation ¶
Index ¶
- Constants
- func GetApplicationGatewayBackendAddressPool() *n.ApplicationGatewayBackendAddressPool
- func GetIngress() (*networking.Ingress, error)
- func GetIngressClass() *networking.IngressClass
- func GetIngressComplex() (*networking.Ingress, error)
- func GetIngressNamespaced() (*[]networking.Ingress, error)
- func GetIngressV1Beta1FromFile(fileName string) (*extensions.Ingress, error)
- func GetIngressV1FromFile(fileName string) (*networking.Ingress, error)
- func GetIngressWithMissingServiceAndServiceWithInvalidPort() *networking.Ingress
- func GetVerySimpleIngress() *networking.Ingress
- func NewEndpointsFixture() *v1.Endpoints
- func NewEndpointsFixtureWithSameNameMultiplePorts() *v1.Endpoints
- func NewHTTPSProbeFixture(containerName string) *v1.Probe
- func NewIngressBackendFixture(serviceName string, port int32) *networking.IngressBackend
- func NewIngressClassFixture() *networking.IngressClass
- func NewIngressFixture() *networking.Ingress
- func NewIngressFixtureSingleSlashPath() *networking.Ingress
- func NewIngressRuleFixture(host string, urlPath string, be networking.IngressBackend) networking.IngressRule
- func NewIngressRuleWithPathsFixture(host string, urlPathsList []string, be networking.IngressBackend) networking.IngressRule
- func NewIngressTestFixture(namespace string, ingressName string) networking.Ingress
- func NewIngressTestFixtureBasic(namespace string, ingressName string, tls bool) *networking.Ingress
- func NewIngressTestWithVariousPathTypeFixture(namespace string, ingressName string) networking.Ingress
- func NewPodFixture(serviceName string, ingressNamespace string, containerName string, ...) *v1.Pod
- func NewPodHTTPSFixture(serviceName string, ingressNamespace string, containerName string, ...) *v1.Pod
- func NewPodTestFixture(namespace string, podName string) v1.Pod
- func NewProbeFixture(containerName string) *v1.Probe
- func NewRewriteRuleSetCustomResourceFixture(name string) *agrewrite.AzureApplicationGatewayRewrite
- func NewRewriteRuleSetCustomResourceFixtureWithoutURLConfig(name string) *agrewrite.AzureApplicationGatewayRewrite
- func NewSecretTestFixture() *v1.Secret
- func NewServiceFixture(servicePorts ...v1.ServicePort) *v1.Service
- func NewServicePortsFixture() *[]v1.ServicePort
Constants ¶
const ( Namespace = "--namespace--" OtherNamespace = "--other-namespace--" HTTPSBackendNamespace = "--https-backend-namespace--" Name = "--name--" Host = "bye.com" OtherHost = "--some-other-hostname--" HostUnassociated = "---some-host-without-routing-rules---" WildcardHost1 = "*.hi.com" WildcardHost2 = "hola.com" NameOfSecret = "--the-name-of-the-secret--" ServiceName = "--service-name--" NodeName = "--node-name--" URLPath1 = "/api1" URLPath2 = "/api2" URLPath3 = "/api3" URLPath4 = "/" URLPath5 = "/*" HealthPath = "/healthz" ContainerName = "--container-name--" ContainerPort = int32(9876) ContainerHealthPortName = "--container-health-port-name--" ContainerHealthHTTPSPortName = "--container-health-https-port-name--" ContainerHealthHTTPSPort = int32(443) ContainerHealthPort = int32(9090) ServicePort = "service-port" SelectorKey = "app" SelectorValue = "frontend" Subscription = "--subscription--" ResourceGroup = "--resource-group--" AppGwName = "--app-gw-name--" PublicIPID = "--front-end-ip-id-1--" PrivateIPID = "--front-end-ip-id-2--" ServiceHTTPPort = "--service-http-port--" ServiceHTTPSPort = "--service-https-port--" IngressClassController = "azure/application-gateway" IngressClassResourceName = "azure-application-gateway" RewriteRuleSetName = "my-rewrite-rule-set-custom-resource" )
constant values to be used for testing
Variables ¶
This section is empty.
Functions ¶
func GetApplicationGatewayBackendAddressPool ¶
func GetApplicationGatewayBackendAddressPool() *n.ApplicationGatewayBackendAddressPool
GetApplicationGatewayBackendAddressPool makes a new ApplicationGatewayBackendAddressPool for testing.
func GetIngress ¶
func GetIngress() (*networking.Ingress, error)
GetIngress creates an Ingress test fixture.
func GetIngressClass ¶
func GetIngressClass() *networking.IngressClass
func GetIngressComplex ¶
func GetIngressComplex() (*networking.Ingress, error)
GetIngressComplex creates an Ingress test fixture with multiple backends and path rules.
func GetIngressNamespaced ¶
func GetIngressNamespaced() (*[]networking.Ingress, error)
GetIngressNamespaced creates 2 Ingress test fixtures in different namespaces.
func GetIngressV1Beta1FromFile ¶
func GetIngressV1Beta1FromFile(fileName string) (*extensions.Ingress, error)
GetIngressV1Beta1FromFile reads an ingress V1Beta1 from file
func GetIngressV1FromFile ¶
func GetIngressV1FromFile(fileName string) (*networking.Ingress, error)
GetIngressV1FromFile reads an ingress V1 from file
func GetIngressWithMissingServiceAndServiceWithInvalidPort ¶
func GetIngressWithMissingServiceAndServiceWithInvalidPort() *networking.Ingress
GetIngressWithMissingServiceAndServiceWithInvalidPort with missing service and service with invalid port
func GetVerySimpleIngress ¶
func GetVerySimpleIngress() *networking.Ingress
GetVerySimpleIngress creates one very simple Ingress test fixture with no rules.
func NewEndpointsFixture ¶
NewEndpointsFixture makes a new endpoint for testing
func NewEndpointsFixtureWithSameNameMultiplePorts ¶
NewEndpointsFixtureWithSameNameMultiplePorts makes a new endpoint for testing
func NewHTTPSProbeFixture ¶
NewHTTPSProbeFixture makes a new probe for testing port 443
func NewIngressBackendFixture ¶
func NewIngressBackendFixture(serviceName string, port int32) *networking.IngressBackend
NewIngressBackendFixture makes a new Ingress Backend for testing
func NewIngressClassFixture ¶
func NewIngressClassFixture() *networking.IngressClass
NewIngressClassFixture creates a new ingress class for testing.
func NewIngressFixture ¶
func NewIngressFixture() *networking.Ingress
NewIngressFixture makes a new Ingress for testing
func NewIngressFixtureSingleSlashPath ¶
func NewIngressFixtureSingleSlashPath() *networking.Ingress
NewIngressFixtureSingleSlashPath makes a new Ingress with "/" and "/*" as ingress rule path for testing
func NewIngressRuleFixture ¶
func NewIngressRuleFixture(host string, urlPath string, be networking.IngressBackend) networking.IngressRule
NewIngressRuleFixture makes a new Ingress Rule for testing
func NewIngressRuleWithPathsFixture ¶
func NewIngressRuleWithPathsFixture(host string, urlPathsList []string, be networking.IngressBackend) networking.IngressRule
NewIngressRuleWithPathsFixture makes a new Ingress Rule with mutiple paths for testing
func NewIngressTestFixture ¶
func NewIngressTestFixture(namespace string, ingressName string) networking.Ingress
NewIngressTestFixture creates a new Ingress struct for testing.
func NewIngressTestFixtureBasic ¶
func NewIngressTestFixtureBasic(namespace string, ingressName string, tls bool) *networking.Ingress
NewIngressTestFixtureBasic creates a basic Ingress with / path for testing.
func NewIngressTestWithVariousPathTypeFixture ¶
func NewIngressTestWithVariousPathTypeFixture(namespace string, ingressName string) networking.Ingress
NewIngressTestFixture creates a new Ingress struct for testing.
func NewPodFixture ¶
func NewPodFixture(serviceName string, ingressNamespace string, containerName string, containerPort int32) *v1.Pod
NewPodFixture makes a new pod for testing
func NewPodHTTPSFixture ¶
func NewPodHTTPSFixture(serviceName string, ingressNamespace string, containerName string, containerPort int32) *v1.Pod
NewPodHTTPSFixture makes a new pod serving at port 443
func NewPodTestFixture ¶
NewPodTestFixture creates a new Pod struct for testing.
func NewProbeFixture ¶
NewProbeFixture makes a new probe for testing
func NewRewriteRuleSetCustomResourceFixture ¶
func NewRewriteRuleSetCustomResourceFixture(name string) *agrewrite.AzureApplicationGatewayRewrite
NewRewriteRuleSetCustomResourceFixture makes a new rewrite rule set custom resource with the given name
func NewRewriteRuleSetCustomResourceFixtureWithoutURLConfig ¶
func NewRewriteRuleSetCustomResourceFixtureWithoutURLConfig(name string) *agrewrite.AzureApplicationGatewayRewrite
func NewSecretTestFixture ¶
NewSecretTestFixture creates a new secret for testing
func NewServiceFixture ¶
func NewServiceFixture(servicePorts ...v1.ServicePort) *v1.Service
NewServiceFixture makes a new service for testing
func NewServicePortsFixture ¶
func NewServicePortsFixture() *[]v1.ServicePort
NewServicePortsFixture makes a new service port for testing
Types ¶
This section is empty.