-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathphpstan.neon
32 lines (32 loc) · 1.85 KB
/
phpstan.neon
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
parameters:
bootstrapFiles:
- './vendor/bin/.phpunit/phpunit/vendor/autoload.php'
- './vendor/autoload.php'
reportUnmatchedIgnoredErrors: false
inferPrivatePropertyTypeFromConstructor: true
level: 7
symfony:
container_xml_path: './src/Resources/config/services.xml'
excludes_analyse:
- %currentWorkingDirectory%/src/Migrations/*
ignoreErrors:
- '#Method Symfony\\Contracts\\EventDispatcher\\EventDispatcherInterface::dispatch\(\) invoked with 2 parameters, 1 required\.#'
- '#Property [^"]+ type mapping mismatch\: property can contain [^"]+\|null but database expects [^"]+.#'
-
message: '#^Service "[^"]+" is private.$#'
path: %rootDir%/../../../tests/
-
message: '#^Service "[^"]+" is not registered in the container.$#'
path: %rootDir%/../../../tests/
# The following ignored errors are from "ergebnis/phpstan-rules" and are too strict.
- '#^Class "[^"]+" is not allowed to extend "[^"]+".$#'
- '#^Class [^"]+ is neither abstract nor final.$#'
- '#^Method [^"]+ is not final, but since the containing class is abstract, it should be.$#'
- '#^Method [^"]+ has a nullable return type declaration.$#'
- '#^Closure has a nullable return type declaration.$#'
- '#^Method [^"]+ has parameter [^"]+ with a nullable type declaration.$#'
- '#^Closure has parameter [^"]+ with a nullable type declaration.$#'
- '#^Method [^"]+ has parameter [^"]+ with null as default value.$#'
- '#^Constructor in [^"]+ has parameter [^"]+ with default value.$#'
- '#^Control structures using switch should not be used.$#'
- '#^Method [^"]+::__construct\(\) has a parameter [^"]+ with a type declaration of Psr\\Container\\ContainerInterface, but containers should not be injected.$#'