File tree Expand file tree Collapse file tree 2 files changed +45
-2
lines changed Expand file tree Collapse file tree 2 files changed +45
-2
lines changed Original file line number Diff line number Diff line change 1- name : " Static analysis "
1+ name : " AutoReview "
22
33on :
44 push :
1010 - cron : ' 0 0 1 * *'
1111
1212jobs :
13- static-analysis :
13+ phpstan :
1414 runs-on : " ubuntu-latest"
1515 name : " PHPStan on PHP ${{ matrix.php }}"
1616 strategy :
3535
3636 - name : " Perform static analysis"
3737 run : " make phpstan"
38+
39+
40+ # This is a "trick", a meta task which does not change, and we can use in
41+ # the protected branch rules as opposed to the E2E tests one above which
42+ # may change regularly.
43+ # This allows us to mark only this job as required instead of each individual
44+ # ever-changing E2E tests.
45+ validate-tests :
46+ name : " AutoReview Status"
47+ runs-on : " ubuntu-latest"
48+ needs :
49+ - " phpstan"
50+ if : " always()"
51+ steps :
52+ - name : " Successful run"
53+ if : " ${{ !(contains(needs.*.result, 'failure')) }}"
54+ run : " exit 0"
55+
56+ - name : " Failing run"
57+ if : " ${{ contains(needs.*.result, 'failure') }}"
58+ run : " exit 1"
Original file line number Diff line number Diff line change 8383
8484 - name : " Run tests"
8585 run : " vendor/bin/phpunit --group e2e"
86+
87+
88+ # This is a "trick", a meta task which does not change, and we can use in
89+ # the protected branch rules as opposed to the E2E tests one above which
90+ # may change regularly.
91+ # This allows us to mark only this job as required instead of each individual
92+ # ever-changing E2E tests.
93+ validate-tests :
94+ name : " Tests Status"
95+ runs-on : " ubuntu-latest"
96+ needs :
97+ - " unit-tests"
98+ - " e2e-tests"
99+ if : " always()"
100+ steps :
101+ - name : " Successful run"
102+ if : " ${{ !(contains(needs.*.result, 'failure')) }}"
103+ run : " exit 0"
104+
105+ - name : " Failing run"
106+ if : " ${{ contains(needs.*.result, 'failure') }}"
107+ run : " exit 1"
You can’t perform that action at this time.
0 commit comments