kube2e

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2019 License: Apache-2.0 Imports: 3 Imported by: 0

README

Regression tests

This directory contains test that install each of the 3 Gloo flavours (gateway, ingress, and knative) and run regression tests against them.

Build test assets

The tests require that a Gloo Helm chart archive be present in the _test folder. This chart will be used to install Gloo to the GKE kube2e-tests cluster (by running glooctl install <deployment-type> -f -test/<chart-archive-name>).

To build the chart, execute the docker and build-test-assets make targets:

make GCLOUD_PROJECT_ID=solo-public BUILD_ID=my-local-build docker build-test-assets

The above command will also build all our docker images and deploy them to Google Container Registry (GCR), where the image references in the chart expect them to be.

Run test

To run the regression tests, your kubeconfig file must point to a running Kubernetes cluster. You can then start the tests by running the following command from this directory:

ginkgo -r

Although running tests in parallel should work, the fact that Gloo creates some cluster-scoped resources is a potential source of problems.

Test environment variables

The below table contains the environment variables that can be used to configure the test execution.

Name Required Description
RUN_KUBE2E_TESTS Y Must be set to 1, otherwise tests will be skipped
DEBUG N Set to 1 for debug log output
WAIT_ON_FAIL N Set to 1 to prevent Ginkgo from cleaning up the Gloo installation in case of failure. Useful to exec into inspect resources created by the test. A command to resume the test run (and thus clean up resources) will be logged to the output.
To run locally:
./hack/test.sh start
eval $(./hack/test.sh kind-env)
make build-kind-assets
export RUN_KUBE2E_TESTS=1
ginkgo -r test/kube2e/

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustKubeClient added in v0.11.2

func MustKubeClient() kubernetes.Interface

Types

This section is empty.

Jump to

Keyboard shortcuts

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