-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathphpstan.neon.dist
49 lines (46 loc) · 2.63 KB
/
phpstan.neon.dist
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
includes:
- vendor/phpstan/phpstan-strict-rules/rules.neon
- vendor/spaze/phpstan-disallowed-calls/extension.neon
- vendor/spaze/phpstan-disallowed-calls/disallowed-dangerous-calls.neon
- vendor/spaze/phpstan-disallowed-calls/disallowed-execution-calls.neon
- vendor/spaze/phpstan-disallowed-calls/disallowed-insecure-calls.neon
- vendor/spaze/phpstan-disallowed-calls/disallowed-loose-calls.neon
- tests/PHPStan/disallowedCalls.neon
- tests/PHPStan/shipmonk.neon
- tests/PHPStan/conditional.config.php
parameters:
level: max
paths:
- src
exceptions:
implicitThrows: false
check:
missingCheckedExceptionInThrows: true
tooWideThrowType: true
uncheckedExceptionClasses:
- LogicException
- Nette\InvalidStateException
- Psr\Container\ContainerExceptionInterface
- Symfony\Component\Messenger\Exception\ExceptionInterface
ignoreErrors:
- '~Call to an undefined method ReflectionType::getName\(\)~'
- # false positive
path: src/MessageBus/StaticAnalysis/ConfigurableHandlerValidator.php
message: "#^Parameter \\#1 \\$type of method Nepada\\\\MessageBus\\\\StaticAnalysis\\\\Rules\\\\ShortClassNameMatchesRule\\:\\:validate\\(\\) expects class\\-string, string given\\.$#"
count: 1
-
message: "#^Method Nepada\\\\MessageBus\\\\StaticAnalysis\\\\ReflectionHelper\\:\\:requireClassReflection\\(\\) has Nepada\\\\MessageBus\\\\StaticAnalysis\\\\StaticAnalysisFailedException in PHPDoc @throws tag but it's not thrown\\.$#"
count: 1
path: src/MessageBus/StaticAnalysis/ReflectionHelper.php
-
message: "#^Dead catch \\- ReflectionException is never thrown in the try block\\.$#"
count: 1
path: src/MessageBus/StaticAnalysis/ReflectionHelper.php
- # false positive
message: "#^Casting to string something that's already string\\.$#"
count: 1
path: src/MessageBus/StaticAnalysis/MessageType.php
-
message: "#^Method Nepada\\\\MessageBus\\\\StaticAnalysis\\\\HandlerType\\:\\:fromHandler\\(\\) should return Nepada\\\\MessageBus\\\\StaticAnalysis\\\\HandlerType\\<T of Nepada\\\\MessageBus\\\\Commands\\\\CommandHandler\\|Nepada\\\\MessageBus\\\\Events\\\\EventSubscriber\\> but returns Nepada\\\\MessageBus\\\\StaticAnalysis\\\\HandlerType\\<Nepada\\\\MessageBus\\\\Commands\\\\CommandHandler\\|Nepada\\\\MessageBus\\\\Events\\\\EventSubscriber\\>\\.$#"
count: 1
path: src/MessageBus/StaticAnalysis/HandlerType.php