diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..2a4ed78 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,17 @@ +language: php + +php: + - 7.1 + +cache: + directories: + - $HOME/.composer/cache + +before_script: + - composer self-update --no-interaction + +jobs: + include: + - stage: PHPStan + install: composer update --prefer-dist + script: vendor/bin/phpstan analyse --configuration phpstan.neon --level 7 src/ diff --git a/composer.json b/composer.json index e09b5f4..dc69e64 100644 --- a/composer.json +++ b/composer.json @@ -9,7 +9,9 @@ }, "require-dev": { "nette/utils": "~2.4", - "nette/reflection": "^2.4" + "nette/reflection": "^2.4", + "phpstan/phpstan-shim": "^0.9.2", + "mockery/mockery": "^1.0" }, "autoload": { "classmap": [ diff --git a/phpstan.neon b/phpstan.neon new file mode 100644 index 0000000..0272aea --- /dev/null +++ b/phpstan.neon @@ -0,0 +1,3 @@ +parameters: + ignoreErrors: + - '#Call to an undefined method Nette\\DI\\Container::setAppContainer\(\)#'