From 9dd423e647df56f1544a5eb26a33fb452d390a39 Mon Sep 17 00:00:00 2001 From: Ian Mindich Date: Mon, 13 Jan 2025 22:19:27 -0800 Subject: [PATCH] Add a single job validate-test-result that will fail will be used to gate pr merges --- .github/workflows/main.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index bd3b21d1000..3f84d55b209 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -253,3 +253,21 @@ jobs: test_results_key: ${{ env.TEST_RESULTS_KEY }} datadog_api_key: ${{ secrets.datadog_api_key }} continue-on-error: true + + validate-test-result: + needs: test + permissions: {} + runs-on: [self-hosted, chrobalt-linux-runner] + name: ${{ matrix.name }}_tests_passing + strategy: + matrix: + platform: ${{ fromJson(needs.initialize.outputs.platforms) }} + include: ${{ fromJson(needs.initialize.outputs.includes) }} + config: [devel] + container: ${{ needs.docker-build-image.outputs.docker_tag }} + steps: + - name: Fail if any test shards have failed + if: ${{ needs.test.result != 'success' }} + run: | + echo "Failing because at least one test shard had errors." + exit 1