Skip to content

Commit

Permalink
composer: added PHPStan
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Dec 10, 2019
1 parent 459bac9 commit 541c388
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
6 changes: 1 addition & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,8 @@ jobs:

- stage: Static Analysis (informative)
php: 7.4
install:
# Install PHPStan
- travis_retry composer create-project phpstan/phpstan-shim temp/phpstan --no-progress
- travis_retry composer install --no-progress --prefer-dist
script:
- php temp/phpstan/phpstan.phar analyse --autoload-file vendor/autoload.php --level 5 src
- vendor/bin/phpstan analyse --level 5 --configuration tests/phpstan.neon src


- stage: Code Coverage
Expand Down
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
},
"require-dev": {
"nette/tester": "^2.2",
"tracy/tracy": "^2.3"
"tracy/tracy": "^2.3",
"phpstan/phpstan-nette": "^0.12"
},
"autoload": {
"classmap": ["src/"]
Expand Down
2 changes: 2 additions & 0 deletions tests/phpstan.neon
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
includes:
- ../vendor/phpstan/phpstan-nette/extension.neon

0 comments on commit 541c388

Please sign in to comment.