Add a second config parameter to test
Some checks failed
Lint Checks / Run linter (pull_request) Successful in 30s
Deploy Test / Run deploy test suite (pull_request) Failing after 4m37s
Webapp Test / Run webapp test suite (pull_request) Successful in 4m7s
K8s Deploy Test / Run deploy test suite on kind/k8s (pull_request) Successful in 7m5s
Smoke Test / Run basic test suite (pull_request) Successful in 4m55s

This commit is contained in:
David Boreham 2024-02-22 12:01:43 -07:00
parent 09e6067faf
commit 9ba6c0f4f7

View File

@ -83,7 +83,7 @@ $TEST_TARGET_SO --stack test deploy down --delete-volumes
# Basic test of creating a deployment # Basic test of creating a deployment
test_deployment_dir=$CERC_REPO_BASE_DIR/test-deployment-dir test_deployment_dir=$CERC_REPO_BASE_DIR/test-deployment-dir
test_deployment_spec=$CERC_REPO_BASE_DIR/test-deployment-spec.yml 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 # Check the file now exists
if [ ! -f "$test_deployment_spec" ]; then if [ ! -f "$test_deployment_spec" ]; then
echo "deploy init test: spec file not present" echo "deploy init test: spec file not present"
@ -141,6 +141,13 @@ else
echo "deployment compose config test: FAILED" echo "deployment compose config test: FAILED"
exit 1 exit 1
fi 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. # Check that the ConfigMap is mounted and contains the expected content.
log_output_4=$( $TEST_TARGET_SO deployment --dir $test_deployment_dir logs ) log_output_4=$( $TEST_TARGET_SO deployment --dir $test_deployment_dir logs )