diff --git a/.travis.yml b/.travis.yml index 6f4defc..59ca3c8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -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 diff --git a/composer.json b/composer.json index ae7a555..0e2b5c6 100644 --- a/composer.json +++ b/composer.json @@ -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/"] diff --git a/tests/phpstan.neon b/tests/phpstan.neon new file mode 100644 index 0000000..60616a1 --- /dev/null +++ b/tests/phpstan.neon @@ -0,0 +1,2 @@ +includes: + - ../vendor/phpstan/phpstan-nette/extension.neon