From 742292da060e6b6be8533eebb9b665b7b19ff68d Mon Sep 17 00:00:00 2001 From: JeromeJu Date: Wed, 5 Jul 2023 13:41:12 +0000 Subject: [PATCH] Refacor install_pipeline_crd SYSTEM_NAMESPACE env setup This commit refactors the setup for `SYSTEM_NAMESPACE` which was previously set in the `install_pipeline_crd` helper function. But it should not be necessary to be part of the pipeline installation instead it is an env setup. This helps resolve the issue where we could not run tests before installing the current version of pipeline CRDs. --- test/e2e-common.sh | 2 -- test/e2e-tests-upgrade.sh | 2 ++ test/e2e-tests.sh | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/test/e2e-common.sh b/test/e2e-common.sh index cd778150023..679585db9be 100755 --- a/test/e2e-common.sh +++ b/test/e2e-common.sh @@ -31,8 +31,6 @@ function install_pipeline_crd() { verify_pipeline_installation verify_resolvers_installation verify_log_access_enabled - - export SYSTEM_NAMESPACE=tekton-pipelines } # Install the Tekton pipeline crd based on the release number diff --git a/test/e2e-tests-upgrade.sh b/test/e2e-tests-upgrade.sh index e9d87934144..d88b0e0ddc2 100755 --- a/test/e2e-tests-upgrade.sh +++ b/test/e2e-tests-upgrade.sh @@ -45,6 +45,8 @@ set -o nounset export SYSTEM_NAMESPACE=tekton-pipelines +export SYSTEM_NAMESPACE=tekton-pipelines + # First, we will verify if Scenario 1 works. # Install the previous release. header "Install the previous release of Tekton pipeline $PREVIOUS_PIPELINE_VERSION" diff --git a/test/e2e-tests.sh b/test/e2e-tests.sh index 15d75139c8d..a291f27e4ba 100755 --- a/test/e2e-tests.sh +++ b/test/e2e-tests.sh @@ -43,6 +43,7 @@ fi header "Setting up environment" install_pipeline_crd +export SYSTEM_NAMESPACE=tekton-pipelines failed=0