Skip to content

Commit

Permalink
Use uptest for e2e testing
Browse files Browse the repository at this point in the history
Signed-off-by: Hasan Turken <[email protected]>
  • Loading branch information
turkenh committed Feb 20, 2024
1 parent ec239f6 commit 5c78a46
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 239 deletions.
28 changes: 20 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,14 +86,26 @@ cobertura:
grep -v zz_generated.deepcopy | \
$(GOCOVER_COBERTURA) > $(GO_TEST_OUTPUT)/cobertura-coverage.xml

# integration tests
e2e.run: test-integration

# Run integration tests.
test-integration: $(KIND) $(KUBECTL) $(UP) $(HELM3)
@$(INFO) running integration tests using kind $(KIND_VERSION)
@KIND_NODE_IMAGE_TAG=${KIND_NODE_IMAGE_TAG} $(ROOT_DIR)/cluster/integration/integration_tests.sh || $(FAIL)
@$(OK) integration tests passed
# ====================================================================================
# End to End Testing
CROSSPLANE_NAMESPACE = crossplane-system
-include build/makelib/local.xpkg.mk
-include build/makelib/controlplane.mk

UPTEST_EXAMPLE_LIST ?= "examples/sample/release.yaml"
uptest: $(UPTEST) $(KUBECTL) $(KUTTL)
@$(INFO) running automated tests
@KUBECTL=$(KUBECTL) KUTTL=$(KUTTL) $(UPTEST) e2e "$(UPTEST_EXAMPLE_LIST)" --setup-script=cluster/test/setup.sh || $(FAIL)
@$(OK) running automated tests

local-dev: controlplane.up
local-deploy: build controlplane.up local.xpkg.deploy.provider.$(PROJECT_NAME)
@$(INFO) running locally built provider
@$(KUBECTL) wait provider.pkg $(PROJECT_NAME) --for condition=Healthy --timeout 5m
@$(KUBECTL) -n crossplane-system wait --for=condition=Available deployment --all --timeout=5m
@$(OK) running locally built provider

e2e: local-deploy uptest

# Update the submodules, such as the common build scripts.
submodules:
Expand Down
213 changes: 0 additions & 213 deletions cluster/integration/integration_tests.sh

This file was deleted.

1 change: 0 additions & 1 deletion cluster/local/config/config.env

This file was deleted.

1 change: 0 additions & 1 deletion cluster/local/config/crossplane/.gitignore

This file was deleted.

8 changes: 0 additions & 8 deletions cluster/local/config/crossplane/config.env

This file was deleted.

3 changes: 0 additions & 3 deletions cluster/local/config/crossplane/value-overrides.yaml.tmpl

This file was deleted.

5 changes: 0 additions & 5 deletions cluster/local/kind.yaml

This file was deleted.

0 comments on commit 5c78a46

Please sign in to comment.