From 122355af14573e27b56def2ab526be04d694939c Mon Sep 17 00:00:00 2001 From: Martin Robinson Date: Tue, 30 Jul 2024 11:02:56 +0200 Subject: [PATCH 1/2] ci: Make it so that the workflow fails is any job fails This is the same setup we have in other Servo repositories. --- .github/workflows/main.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b3768cae..fc818da8 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -85,16 +85,17 @@ jobs: build_result: name: Result runs-on: ubuntu-latest + if: always() needs: - "linux-ci" - "mac-ci" - "windows-ci" steps: - - name: Mark the job as successful + - name: Success run: exit 0 - if: success() - - name: Mark the job as unsuccessful + if: ${{ !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') }} + - name: Failure run: exit 1 - if: "!success()" + if: contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') From a8809c8aaa5b5d59e69a4e973f7b056cab462d2f Mon Sep 17 00:00:00 2001 From: Martin Robinson Date: Tue, 30 Jul 2024 11:10:45 +0200 Subject: [PATCH 2/2] Cause a failure --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index fc818da8..19e64418 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -54,7 +54,7 @@ jobs: run: cargo build --features "${{ matrix.features }}" - name: Cargo test - run: cargo test --features "${{ matrix.features }}" + run: cargo test --features blahbalh "${{ matrix.features }}" env: RUST_BACKTRACE: 1