-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathphpcs.xml.dist
68 lines (53 loc) · 2.36 KB
/
phpcs.xml.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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<?xml version="1.0"?>
<ruleset
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="./vendor/squizlabs/php_codesniffer/phpcs.xsd">
<arg name="basepath" value="."/>
<arg name="cache" value=".phpcs-cache"/>
<arg name="colors"/>
<arg name="extensions" value="php"/>
<arg name="parallel" value="80"/>
<!-- Show progress -->
<arg value="p"/>
<!-- Paths to check -->
<file>src</file>
<file>test</file>
<!-- Include all rules from Laminas Coding Standard -->
<rule ref="LaminasCodingStandard"/>
<!-- Run against the PHPCompatibility ruleset -->
<rule ref="PHPCompatibility"/>
<config name="testVersion" value="5.6-"/>
<!-- Omit checks for constant visibility, as 5.6 does not support it -->
<rule ref="PSR12.Properties.ConstantVisibility.NotFound">
<exclude-pattern>src/MbEreg\.php</exclude-pattern>
</rule>
<!-- Omit checks for declare_strict, as 5.6 does not support it -->
<rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes.DeclareStrictTypesMissing">
<exclude-pattern>src/*\.php</exclude-pattern>
</rule>
<!-- Omit phpcompat checks against test suite; suite runs on 7.3+ -->
<rule ref="PHPCompatibility.Classes.NewAnonymousClasses.Found">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
<rule ref="PHPCompatibility.ControlStructures.NewExecutionDirectives.strict_typesFound">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
<rule ref="PHPCompatibility.FunctionDeclarations.NewNullableTypes.typeDeclarationFound">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
<rule ref="PHPCompatibility.FunctionDeclarations.NewParamTypeDeclarations.stringFound">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
<rule ref="PHPCompatibility.FunctionDeclarations.NewReturnTypeDeclarations.arrayFound">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
<rule ref="PHPCompatibility.FunctionDeclarations.NewReturnTypeDeclarations.stringFound">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
<rule ref="PHPCompatibility.FunctionDeclarations.NewReturnTypeDeclarations.voidFound">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
<rule ref="PHPCompatibility.FunctionUse.RemovedFunctions.mberegDeprecated">
<exclude-pattern>test/*Test.php</exclude-pattern>
</rule>
</ruleset>