Skip to content

Commit dd94e46

Browse files
authored
Perform more code quality checks
1 parent 5542a00 commit dd94e46

File tree

1 file changed

+44
-1
lines changed

1 file changed

+44
-1
lines changed

phpcs-simplesamlphp.xml

Lines changed: 44 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<?xml version="1.0"?>
22
<ruleset name="SimpleSAMLphp">
3-
43
<!-- Only allow shorthand array syntax -->
54
<rule ref="Generic.Arrays.DisallowLongArraySyntax" />
65

@@ -12,6 +11,9 @@
1211

1312
<config name="installed_paths" value="vendor/slevomat/coding-standard"/>
1413

14+
<!-- Use fully qualified class names in annotations and PHPdoc -->
15+
<rule ref="SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameInAnnotation" />
16+
1517
<!-- Do not allow any unused use-statements to exist -->
1618
<rule ref="SlevomatCodingStandard.Namespaces.UnusedUses" />
1719

@@ -24,4 +26,45 @@
2426
<rule ref="SlevomatCodingStandard.Functions.RequireTrailingCommaInClosureUse" />
2527
<rule ref="SlevomatCodingStandard.Functions.RequireTrailingCommaInDeclaration" />
2628

29+
<!-- Require one blank line between different types of use-statements -->
30+
<rule ref="SlevomatCodingStandard.Namespaces.UseSpacing">
31+
<properties>
32+
<property name="linesCountBetweenUseTypes="1" />
33+
</properties>
34+
</rule>
35+
36+
<!-- Require two blank lines between class members -->
37+
<rule ref="SlevomatCodingStandard.Classes.ClassMemberSpacing">
38+
<properties>
39+
<property name="linesCountBetweenMembers="2" />
40+
</properties>
41+
</rule>
42+
43+
<!-- Require one blank line between constant declarations -->
44+
<rule ref="SlevomatCodingStandard.Classes.ConstantSpacing">
45+
<properties>
46+
<property name="minLinesCountBeforeWithComment="1" />
47+
<property name="maxLinesCountBeforeWithComment="1" />
48+
<property name="minLinesCountBeforeWithoutComment="1" />
49+
<property name="maxLinesCountBeforeWithoutComment="1" />
50+
</properties>
51+
</rule>
52+
53+
<!-- Require one blank line between property definitions -->
54+
<rule ref="SlevomatCodingStandard.Classes.PropertySpacing">
55+
<properties>
56+
<property name="minLinesCountBeforeWithComment="1" />
57+
<property name="maxLinesCountBeforeWithComment="1" />
58+
<property name="minLinesCountBeforeWithoutComment="1" />
59+
<property name="maxLinesCountBeforeWithoutComment="1" />
60+
</properties>
61+
</rule>
62+
63+
<!-- Require two blank lines between method declarations -->
64+
<rule ref="SlevomatCodingStandard.Classes.MethodSpacing ">
65+
<properties>
66+
<property name="minLinesCount="2" />
67+
<property name="maxLinesCount="2" />
68+
</properties>
69+
</rule>
2770
</ruleset>

0 commit comments

Comments
 (0)