forked from zenstruck/foundry
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathphpstan.neon
39 lines (35 loc) · 1.34 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
33
34
35
36
37
38
39
includes:
- phpstan-baseline.neon
parameters:
inferPrivatePropertyTypeFromConstructor: true
checkMissingIterableValueType: false
checkUninitializedProperties: true
checkGenericClassInNonGenericObjectType: false
paths:
- ./src
# let's analyse factories generated with maker
- ./tests/Fixtures/Maker/expected/can_create_factory_for_entity_with_repository_with_data_set_phpstan.php
- ./tests/Fixtures/Maker/expected/can_create_factory_with_static_analysis_annotations_with_data_set_phpstan.php
level: 8
bootstrapFiles:
- ./vendor/autoload.php
banned_code:
nodes:
# enable detection of die/exit
-
type: Expr_Exit
functions: null
# enable detection of a set of functions
-
type: Expr_FuncCall
functions:
- dd
- debug_backtrace
- dump
- print_r
- var_dump
excludePaths:
- ./src/Bundle/Resources
# phpstan runs with orm 3 - there are too many failures in these files which are compatible with orm 2
- ./src/Bundle/Maker/Factory/LegacyORMDefaultPropertiesGuesser.php
- ./src/Bundle/Maker/Factory/DoctrineScalarFieldsDefaultPropertiesGuesser.php