File tree Expand file tree Collapse file tree 2 files changed +61
-32
lines changed
Expand file tree Collapse file tree 2 files changed +61
-32
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ name : Tests
2+
3+ on :
4+ push :
5+ branches : [ main, master ]
6+ pull_request :
7+ release :
8+ types : [ created ]
9+
10+ jobs :
11+ unit-tests :
12+ runs-on : ${{ matrix.operating-system }}
13+ strategy :
14+ matrix :
15+ operating-system : [ ubuntu-latest ]
16+ php-versions :
17+ - ' 7.2'
18+ - ' 7.3'
19+ - ' 7.4'
20+ - ' 8.0'
21+ - ' 8.1'
22+ name : PHP ${{ matrix.php-versions }} Test on ${{ matrix.operating-system }}
23+
24+ steps :
25+ - name : Checkout
26+ uses : actions/checkout@v3
27+
28+ - name : Setup PHP
29+ uses : shivammathur/setup-php@v2
30+ with :
31+ php-version : ${{ matrix.php-versions }}
32+ extensions : mbstring, intl, zip, xml
33+ coverage : none
34+
35+ - name : Install dependencies
36+ uses : ramsey/composer-install@v2
37+
38+ - name : Update PHPUnit
39+ run : composer update phpunit/phpunit --with-dependencies
40+
41+ - name : Run test suite
42+ run : vendor/bin/phpunit --exclude-group mayignore --coverage-clover build/logs/clover.xml
43+
44+
45+ # This is a "trick", a meta task which does not change, and we can use in
46+ # the protected branch rules as opposed to the tests one above which
47+ # may change regularly.
48+ validate-tests :
49+ name : Tests status
50+ runs-on : ubuntu-latest
51+ needs :
52+ - unit-tests
53+ if : always()
54+ steps :
55+ - name : Successful run
56+ if : ${{ !(contains(needs.*.result, 'failure')) }}
57+ run : exit 0
58+
59+ - name : Failing run
60+ if : ${{ contains(needs.*.result, 'failure') }}
61+ run : exit 1
You can’t perform that action at this time.
0 commit comments