diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a128771..e73e4a2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -89,3 +89,20 @@ jobs: if (KNOWN_EVENT_TYPES.length === 0 || METRIC_TYPES.length === 0) throw new Error('model constants missing'); console.log('pack smoke ok: guardagent imports from the packed tarball'); " + + ci: + # The context master-rule requires: it reports on every run and fails when a job above failed or was + # cancelled. A skipped job counts as passed. + if: always() + needs: [lint, test, pack-smoke] + runs-on: ubuntu-latest + timeout-minutes: 5 + steps: + - name: Every job above succeeded or was skipped + env: + RESULTS: ${{ join(needs.*.result, ' ') }} + run: | + echo "needs: $RESULTS" + for result in $RESULTS; do + case "$result" in failure|cancelled) exit 1 ;; esac + done