Skip to content

Commit

Permalink
tests: make megajob block on failure
Browse files Browse the repository at this point in the history
GitHub Actions considers a "skipped" job successful for the purposes
of required jobs for branch protections. We take advantage of this
by failing if any dependent actions failed, or "skip" if they all
succeeded.
  • Loading branch information
cole-h committed May 29, 2024
1 parent c6857b9 commit 676d200
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,13 @@ jobs:
- install-nix-linux
- install-nix-macos
- install-with-non-default-source-inputs
# NOTE(cole-h): GitHub treats "skipped" as "OK" for the purposes of required checks on branch
# protection, so we take advantage of this fact and fail if any of the dependent actions failed,
# or "skip" (which is a success for GHA's purposes) if none of them did.
if: failure()
steps:
- run: true
- name: Dependent checks failed
run: exit 1

check-dist-up-to-date:
name: Check the dist/ folder is up to date
Expand Down

0 comments on commit 676d200

Please sign in to comment.