From fb3f4321bb994dfc958751764f4387736cda6e99 Mon Sep 17 00:00:00 2001 From: Craig O'Donnell Date: Tue, 26 Sep 2023 12:33:02 -0400 Subject: [PATCH] add test coverage --- .github/workflows/build-test.yaml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/.github/workflows/build-test.yaml b/.github/workflows/build-test.yaml index 5946b4430d..edf0d412c2 100644 --- a/.github/workflows/build-test.yaml +++ b/.github/workflows/build-test.yaml @@ -3261,6 +3261,33 @@ jobs: sleep 1 done + # validate that the conditional chart is installed + COUNTER=1 + while [ "$(helm ls -n "$APP_SLUG" | awk 'NR>1{print $1}' | grep my-conditional-chart-release)" == "" ]; do + ((COUNTER += 1)) + if [ $COUNTER -gt 120 ]; then + echo "Timed out waiting for my-conditional-chart-release to be installed" + helm ls -n "$APP_SLUG" + exit 1 + fi + sleep 1 + done + + # toggle the config option to exclude the conditional chart + ./bin/kots set config "$APP_SLUG" install_conditional_chart=false --deploy --namespace "$APP_SLUG" + + # wait for my-conditional-chart-release to be uninstalled + COUNTER=1 + while [ "$(helm ls -n "$APP_SLUG" | awk 'NR>1{print $1}' | grep my-conditional-chart-release)" != "" ]; do + ((COUNTER += 1)) + if [ $COUNTER -gt 120 ]; then + echo "Timed out waiting for my-conditional-chart-release to be uninstalled" + helm ls -n "$APP_SLUG" + exit 1 + fi + sleep 1 + done + - name: Generate support bundle on failure if: failure()