This repository was archived by the owner on Aug 7, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +69
-0
lines changed Expand file tree Collapse file tree 2 files changed +69
-0
lines changed Original file line number Diff line number Diff line change 1+ name : " coding standards"
2+
3+ on : ["pull_request", "push"]
4+
5+ jobs :
6+ coding-standards :
7+ name : " coding standards"
8+ runs-on : " ubuntu-latest"
9+ steps :
10+ - name : " checkout"
11+ uses : " actions/checkout@v2"
12+
13+ - name : " installing PHP"
14+ uses : " shivammathur/setup-php@v2"
15+ with :
16+ php-version : " 8.0"
17+ ini-values : memory_limit=-1
18+ tools : composer:v2, cs2pr, php-cs-fixer
19+
20+ - name : " checking"
21+ run : " php-cs-fixer fix --dry-run --diff --ansi"
Original file line number Diff line number Diff line change 1+ name : " unit tests"
2+
3+ on : ["pull_request", "push"]
4+
5+ jobs :
6+ unit-tests :
7+ name : " unit tests"
8+ runs-on : " ubuntu-latest"
9+ strategy :
10+ matrix :
11+ php-version :
12+ - " 8.0"
13+ steps :
14+ - name : " checkout"
15+ uses : " actions/checkout@v2"
16+
17+ - name : " installing PHP"
18+ uses : " shivammathur/setup-php@v2"
19+ with :
20+ php-version : " ${{ matrix.php-version }}"
21+ tools : composer:v2, cs2pr
22+ coverage : pcov
23+ ini-values : memory_limit=-1
24+
25+ - name : " get composer cache directory"
26+ id : composer-cache
27+ run : echo "::set-output name=dir::$(composer config cache-files-dir)"
28+
29+ - name : " cache dependencies"
30+ uses : actions/cache@v2
31+ with :
32+ path : ${{ steps.composer-cache.outputs.dir }}
33+ key : ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
34+ restore-keys : ${{ runner.os }}-composer-
35+
36+ - name : " install dependencies"
37+ run : composer install --prefer-dist
38+
39+ - name : " running unit tests"
40+ run : vendor/bin/phpunit
41+
42+ - name : " upload coverage results to Codecov"
43+ uses : codecov/codecov-action@v1
44+ with :
45+ name : " phpunit-php${{ matrix.php-version }}"
46+ flags : phpunit
47+ fail_ci_if_error : true
48+ continue-on-error : true
You can’t perform that action at this time.
0 commit comments