diff --git a/.github/workflows/run-api-test.yml b/.github/workflows/run-api-test.yml index 7b7cbd8c9e..ab6b96a20f 100644 --- a/.github/workflows/run-api-test.yml +++ b/.github/workflows/run-api-test.yml @@ -142,18 +142,13 @@ jobs: steps: - run: | VALID_FAILURE_EXIT_CODES="53" - - # Create an array to store exit codes - exit_codes=() - - # Loop through each matrix job - for result in "${{ needs.api-test[*].outputs.exit_code }}"; do - echo "Exit code from branch: $result" - exit_codes+=("$result") - done - + echo "consolidated:" + echo "{{ needs.api-test.outputs.exit_code | join(",") }}" + echo "alt:" + echo "{{ needs.api-test.outputs.exit_code }}" + exit_codes='[{{ needs.api-test.outputs.exit_code | join(",") }}] | jq -r '.[]'' # Check if any exit code is "bad" - for code in "${exit_codes[@]}"; do + for code in $exit_codes; do if echo "$VALID_FAILURE_EXIT_CODES" | grep -qw "$code"; then echo "Bad exit code detected: $code" curl --location "${{ secrets.FIREHYDRANT_WEBHOOK_URL }}" \