From 60b224b65445316359a1c330debf918ce32058c9 Mon Sep 17 00:00:00 2001 From: ADmad Date: Sat, 12 Aug 2017 02:23:42 +0530 Subject: [PATCH] Bump up phpstan to level 2. --- .travis.yml | 2 +- phpstan.neon | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 341e10ce55e..8943e92a768 100644 --- a/.travis.yml +++ b/.travis.yml @@ -75,7 +75,7 @@ script: - if [[ $DEFAULT = 1 && $TRAVIS_PHP_VERSION != 7.0 ]]; then vendor/bin/phpunit; fi - if [[ $PHPCS = 1 ]]; then composer cs-check; fi - - if [[ $PHPSTAN = 1 ]]; then composer require --dev phpstan/phpstan:^0.8 && vendor/bin/phpstan analyse -c phpstan.neon -l 1 src; fi + - if [[ $PHPSTAN = 1 ]]; then composer require --dev phpstan/phpstan:^0.8 && vendor/bin/phpstan analyse -c phpstan.neon -l 2 src; fi after_success: - if [[ $DEFAULT = 1 && $TRAVIS_PHP_VERSION = 7.0 ]]; then bash <(curl -s https://codecov.io/bash); fi diff --git a/phpstan.neon b/phpstan.neon index 85658cd7d12..1aed237ef58 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -16,6 +16,14 @@ parameters: - '#Access to an undefined property Cake\\Database\\Driver::\$_connection#' - '#Constant XC_TYPE_VAR not found#' - '#Class PHPUnit_Runner_Version not found and could not be autoloaded#' + - '#Call to an undefined method Cake\\Auth\\Storage\\StorageInterface::getConfig\(\)#' + - '#Call to an undefined method Cake\\Auth\\Storage\\StorageInterface::setConfig\(\)#' + - '#Call to an undefined method Psr\\Http\\Message\\ResponseInterface::getCookies\(\)#' + - '#Access to an undefined property Psr\\Http\\Message\\UriInterface::\$webroot#' + - '#Access to an undefined property Psr\\Http\\Message\\UriInterface::\$base#' + - '#Call to an undefined method Cake\\Collection\\Iterator\\ZipIterator::getInnerIterator\(\)#' + - '#Result of method Cake\\Http\\Response::send\(\) \(void\) is used#' + - '#Method Cake\\View\\Form\\ContextInterface::val\(\) invoked with 2 parameters, 1 required#' earlyTerminatingMethodCalls: Cake\Shell\Shell: - abort