File tree Expand file tree Collapse file tree 2 files changed +24
-9
lines changed
Expand file tree Collapse file tree 2 files changed +24
-9
lines changed Original file line number Diff line number Diff line change 11name : CI
22
3- on : [push]
3+ on : [push,pull_request]
4+
5+ permissions :
6+ contents : read
47
58jobs :
6- build-test :
9+ build :
710 runs-on : ubuntu-latest
811
912 steps :
10- - uses : actions/checkout@v2
13+ - uses : actions/checkout@v3
1114
12- - uses : php-actions/composer@v5
15+ - name : Validate composer.json and composer.lock
16+ run : composer validate --strict
1317
14- - name : PHPUnit Tests
15- uses : php-actions/phpunit@v2
18+ - name : Cache Composer packages
19+ id : composer-cache
20+ uses : actions/cache@v3
1621 with :
17- bootstrap : vendor/autoload.php
18- configuration : test/phpunit.xml
19- args : --coverage-text
22+ path : vendor
23+ key : ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
24+ restore-keys : |
25+ ${{ runner.os }}-php-
26+
27+ - name : Install dependencies
28+ run : composer install --prefer-dist --no-progress
29+
30+ - name : Run test suite
31+ run : composer run-script test
Original file line number Diff line number Diff line change 2626 "psr-4" : {
2727 "YOCLIB\\ OpenLocationCode\\ Tests\\ " : " tests/"
2828 }
29+ },
30+ "scripts" : {
31+ "test" : " phpunit"
2932 }
3033}
You can’t perform that action at this time.
0 commit comments