@@ -565,12 +565,25 @@ jobs:
565
565
566
566
required :
567
567
runs-on :ubuntu-latest
568
- needs :[test-go, test-go-pg, test-js]
569
- # allow this job to run even if the previous jobs are skipped
570
- if :|
571
- always() &&
572
- !contains(needs.*.result, 'failure') &&
573
- !contains(needs.*.result, 'cancelled')
568
+ needs :[gen, test-go, test-go-pg, test-go-race, test-js]
569
+ # Allow this job to run even if the needed jobs fail, are skipped or
570
+ # cancelled.
571
+ if :always()
574
572
steps :
575
573
-name :Ensure required checks
576
- run :echo "Required checks have passed"
574
+ run :|
575
+ echo "Checking required checks"
576
+ echo "- gen: ${{ needs.gen.result }}"
577
+ echo "- test-go: ${{ needs.test-go.result }}"
578
+ echo "- test-go-pg: ${{ needs.test-go-pg.result }}"
579
+ echo "- test-go-race: ${{ needs.test-go-race.result }}"
580
+ echo "- test-js: ${{ needs.test-js.result }}"
581
+ echo
582
+
583
+ # We allow skipped jobs to pass, but not failed or cancelled jobs.
584
+ if [[ "${{ contains(needs.*.result, 'failure') }}" == "true" || "${{ contains(needs.*.result, 'cancelled') }}" == "true" ]]; then
585
+ echo "One of the required checks has failed or has been cancelled"
586
+ exit 1
587
+ fi
588
+
589
+ echo "Required checks have passed"