File tree Expand file tree Collapse file tree 3 files changed +48
-1
lines changed Expand file tree Collapse file tree 3 files changed +48
-1
lines changed Original file line number Diff line number Diff line change 1+ name : phpstan
2+
3+ on :
4+ push :
5+ branches : [master]
6+ pull_request :
7+ branches : [master]
8+
9+ jobs :
10+ phpstan :
11+
12+ runs-on : ubuntu-latest
13+
14+ steps :
15+ - uses : actions/checkout@v3
16+
17+ - name : Setup PHP
18+ uses : shivammathur/setup-php@v2
19+ with :
20+ php-version : 8.1
21+
22+ - name : Cache Composer packages
23+ id : composer-cache
24+ uses : actions/cache@v3
25+ with :
26+ path : vendor
27+ key : ${{ runner.os }}-php81-${{ hashFiles('**/composer.lock') }}
28+ restore-keys : |
29+ ${{ runner.os }}-php81-
30+
31+ - name : Install dependencies
32+ if : steps.composer-cache.outputs.cache-hit != 'true'
33+ run : |
34+ composer install
35+ composer dump
36+
37+ - name : Run analyse phpstan
38+ run : vendor/bin/phpstan analyse --error-format github
Original file line number Diff line number Diff line change 3232 "test" : " vendor/bin/phpunit"
3333 },
3434 "require-dev" : {
35- "phpunit/phpunit" : " ^9.0"
35+ "phpunit/phpunit" : " ^9.0" ,
36+ "phpstan/phpstan" : " ^1.9"
3637 }
3738}
Original file line number Diff line number Diff line change 1+ parameters:
2+
3+ paths:
4+ - src
5+ - tests
6+
7+ # The level 9 is the highest level
8+ level: 5
You can’t perform that action at this time.
0 commit comments