-
-
Notifications
You must be signed in to change notification settings - Fork 27
/
phpcs.xml.dist
33 lines (28 loc) · 1.26 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
<?xml version="1.0"?>
<ruleset>
<file>bootstrap.php</file>
<file>src/</file>
<file>tests/</file>
<exclude-pattern>tests/data/*</exclude-pattern>
<exclude-pattern>tests/functions.php</exclude-pattern>
<exclude-pattern>tests/WP_UnitTestCase_Base.php</exclude-pattern>
<rule ref="PSR12NeutronRuleset">
<exclude name="Generic.Files.LineLength"/>
<exclude name="PEAR.Commenting.ClassComment"/>
<exclude name="PEAR.Commenting.FileComment"/>
</rule>
<!-- PHPCS does not understand yield -->
<rule ref="NeutronStandard.Functions.TypeHint.UnusedReturnType">
<exclude-pattern>tests/AssertMethodTypeSpecifyingExtensionTest.php</exclude-pattern>
<exclude-pattern>tests/DynamicReturnTypeExtensionTest.php</exclude-pattern>
</rule>
<!-- Allow string concatenation in tests -->
<rule ref="PSR12NeutronRuleset.Strings.ConcatenationUsage.NotAllowed">
<exclude-pattern>tests/*</exclude-pattern>
</rule>
<!-- Allow long functions in test cases -->
<rule ref="SlevomatCodingStandard.Functions.FunctionLength.FunctionLength">
<exclude-pattern>tests/HookDocsRuleTest.php</exclude-pattern>
<exclude-pattern>tests/HookCallbackRuleTest.php</exclude-pattern>
</rule>
</ruleset>