End-to-end (E2E) tests can be executed using make test-e2e. You must modify test/e2e/config/config.yaml before running.
Running Non-Hosted Templates (Local/Standalone)
Use this for standalone, adopted, or remote tests where you want to run everything locally using local images and registries.
make KIND_CLUSTER_NAME="kcm-test" CLUSTER_DEPLOYMENT_PREFIX="<your-cluster-name-prefix>" GINKGO_LABEL_FILTER="<optional>" REGISTRY_REPO="oci://127.0.0.1:5001/charts" VERSION=1.0.0 IMG=localhost/kcm/controller:1.0.0 IMG_TELEMETRY=localhost/kcm/telemetry:1.0.0 kind-deploy registry-deploy set-kcm-version dev-push test-e2e
Running Hosted Templates
Requires a prior CI run to ensure manifests, images, and charts are available in the registry.
make KIND_CLUSTER_NAME="kcm-test" CLUSTER_DEPLOYMENT_PREFIX="<your-cluster-name-prefix>" GINKGO_LABEL_FILTER="<optional>" IMG="ghcr.io/k0rdent/kcm/staging/controller:<version-from-ci>" IMG_TELEMETRY="ghcr.io/k0rdent/kcm/staging/telemetry:<version-from-ci>" VERSION=<version-from-ci> REGISTRY_REPO="oci://127.0.0.1:5001/charts" set-kcm-version test-e2e
Filtering Tests
Use GINKGO_LABEL_FILTER to run specific subsets of tests (e.g., only AWS tests) to save time. To see all available labels, run ginkgo labels ./test/e2e.
Example for AWS only:
make GINKGO_LABEL_FILTER="provider:aws" [OTHER_VARIABLES] test-e2e
# Example: Running non-hosted tests locally
make KIND_CLUSTER_NAME="kcm-test" CLUSTER_DEPLOYMENT_PREFIX="my-prefix" GINKGO_LABEL_FILTER="" REGISTRY_REPO="oci://127.0.0.1:5001/charts" VERSION=1.0.0 IMG=localhost/kcm/controller:1.0.0 IMG_TELEMETRY=localhost/kcm/telemetry:1.0.0 kind-deploy registry-deploy set-kcm-version dev-push test-e2e