From 9ba6c0f4f735399426117c2c191e4d28f40ada1a Mon Sep 17 00:00:00 2001 From: David Boreham Date: Thu, 22 Feb 2024 12:01:43 -0700 Subject: [PATCH] Add a second config parameter to test --- tests/deploy/run-deploy-test.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/deploy/run-deploy-test.sh b/tests/deploy/run-deploy-test.sh index 9dec2d46..fb574b03 100755 --- a/tests/deploy/run-deploy-test.sh +++ b/tests/deploy/run-deploy-test.sh @@ -83,7 +83,7 @@ $TEST_TARGET_SO --stack test deploy down --delete-volumes # Basic test of creating a deployment test_deployment_dir=$CERC_REPO_BASE_DIR/test-deployment-dir test_deployment_spec=$CERC_REPO_BASE_DIR/test-deployment-spec.yml -$TEST_TARGET_SO --stack test deploy init --output $test_deployment_spec --config CERC_TEST_PARAM_1=PASSED +$TEST_TARGET_SO --stack test deploy init --output $test_deployment_spec --config CERC_TEST_PARAM_1=PASSED,CERC_TEST_PARAM_3=FAST # Check the file now exists if [ ! -f "$test_deployment_spec" ]; then echo "deploy init test: spec file not present" @@ -141,6 +141,13 @@ else echo "deployment compose config test: FAILED" exit 1 fi +# Check the config variable CERC_TEST_PARAM_3 was passed correctly +if [[ "$log_output_3" == *"Test-param-3: FAST"* ]]; then + echo "deployment config test: passed" +else + echo "deployment config test: FAILED" + exit 1 +fi # Check that the ConfigMap is mounted and contains the expected content. log_output_4=$( $TEST_TARGET_SO deployment --dir $test_deployment_dir logs )