Files
Grav/tests/phpstan/phpstan.neon
Sébastien Vanvelthem ecd39421d6 Some phpstan issues (#2393)
* Fix bug, method init must be protected
* Added phpstan level 0
* Added exclusions
* Fix: incorrect case in Twig_SimpleFunction
* Fix, no abstract properties, if properties used in methods let's set them
* Fixed Psr\SimpleCache\InvalidArgumentException referenced with incorrect case
* added exclusions
* Fixed: Access to an undefined property Grav\Framework\Form\FormFlash::$uploadObjects.
* Fixed: does not call parent constructor from Grav\Common\Iterator.
* Fixed: does not call parent constructor from Grav\Common\Iterator.
* Fixed: does not call parent constructor
* Fixed: does not call parent constructor
* Minor: correct type for inflector
* Moved phpstan.neon out of public directory
* Added exclusion
* set GRAV_USER_INSTANCE to prevent LogiException in User
* Exlude Stream:create
* Minor: Missing storage property
* Minor: Fixed missing properties (phpstan level 1)
* Added type for $data
* Minor: Ensure $langs is initialized
* Fix possible bug in $http_response_header status code retrieval (PHP 7.1 only)
* Added exclusion for $http_response_header (isset is actually not required)
* Strict null check
2019-03-13 08:15:22 +02:00

55 lines
1.9 KiB
Plaintext

includes:
#- vendor/phpstan/phpstan-strict-rules/rules.neon
parameters:
fileExtensions:
- php
- dist
bootstrap: tests/phpstan/phpstan-bootstrap.php
excludes_analyse:
- system/src/Grav/Common/Errors/Resources/layout.html.php
reportUnmatchedIgnoredErrors: true
ignoreErrors:
# Errors that needs some more thinking (design...)
# Needed: full coverage (probably with admin plugin...) then redesign constructor
-
message: '#Grav\\Common\\GPM\\Remote\\GravCore::__construct\(\) does not call parent constructor from Grav\\Common\\GPM\\Remote\\AbstractPackageCollection#'
path: system/src/Grav/Common/GPM/Remote/GravCore.php
# Needed: psr-17 (http-factories) support (through decorator or further investigations)
-
message: '#Call to an undefined static method Grav\\Framework\\Psr7\\Stream::create\(\).#'
path: system/src/Grav/Framework/Form/FormFlashFile.php
# Those errors are about plugins (need to find a better solution)
-
message: '#Call to static method sendEmail\(\) on an unknown class Grav\\Plugin\\Email\\Utils.#'
path: system/src/Grav/Common/Scheduler/Job.php
# Can be ignored, after fopen there's always an $http_response_header locally available
-
message: '#Variable \$http_response_header in isset\(\) always exists and is not nullable.#'
path: system/src/Grav/Common/GPM/Response.php
# Those errors can be ignored (they depends on installed extensions)
-
message: '#Instantiated class Memcache not found#'
path: system/src/Grav/Common/Cache.php
-
message: '#Instantiated class Redis not found#'
path: system/src/Grav/Common/Cache.php
-
message: '#Instantiated class RedisException not found#'
path: system/src/Grav/Common/Cache.php