diff --git a/.gitignore b/.gitignore index 0e32d36..805728d 100644 --- a/.gitignore +++ b/.gitignore @@ -13,7 +13,7 @@ Dockerfile.cross # Test/Intermediate files database.sql load-data.sh -local-demo-data.sh +local-demo-data.sql # Output of the go coverage tool, specifically when used with LiteIDE *.out diff --git a/Makefile b/Makefile index ff29812..c365978 100644 --- a/Makefile +++ b/Makefile @@ -238,24 +238,25 @@ generate_mocks: ## TODO: auto install go install go.uber.org/mock/mockgen@latest mockgen -destination ${GEN_DIR}/${NETBOX_MOCKS_OUTPUT_FILE} -source=${INTERFACE_DEFITIONS_DIR} # e2e tests - +# setting parallel to 2 to avoid flakiness +E2E_PARAM := --namespace e2e --parallel 2 --apply-timeout 30s --assert-timeout 1m .PHONY: create-kind-3.7.8 create-kind-3.7.8: ./kind/local-env.sh --version 3.7.8 .PHONY: test-e2e-3.7.8 test-e2e-3.7.8: create-kind-3.7.8 deploy-kind install-$(GO_PACKAGE_NAME_CHAINSAW) - chainsaw test --namespace e2e + chainsaw test $(E2E_PARAM) .PHONY: create-kind-4.0.11 create-kind-4.0.11: ./kind/local-env.sh --version 4.0.11 .PHONY: test-e2e-4.0.11 test-e2e-4.0.11: create-kind-4.0.11 deploy-kind install-$(GO_PACKAGE_NAME_CHAINSAW) - chainsaw test --namespace e2e + chainsaw test $(E2E_PARAM) .PHONY: create-kind-4.1.7 create-kind-4.1.7: ./kind/local-env.sh --version 4.1.7 .PHONY: test-e2e-4.1.7 test-e2e-4.1.7: create-kind-4.1.7 deploy-kind install-$(GO_PACKAGE_NAME_CHAINSAW) - chainsaw test --namespace e2e + chainsaw test $(E2E_PARAM) diff --git a/kind/local-env.sh b/kind/local-env.sh index 63f32d3..0331be9 100755 --- a/kind/local-env.sh +++ b/kind/local-env.sh @@ -90,6 +90,9 @@ elif [[ "${VERSION}" == "4.1.7" ]] ;then "ghcr.io/zalando/postgres-operator:v1.12.2" \ "ghcr.io/zalando/spilo-16:3.2-p3" \ ) + + cp $(dirname "$0")/load-data-job/load-data.orig.sh $(dirname "$0")/load-data-job/load-data.sh + cp $(dirname "$0")/load-data-job/local-demo-data.orig.sql $(dirname "$0")/load-data-job/local-demo-data.sql else echo "Unknown version ${VERSION}" exit 1