-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FEATURE] add phpcs, phpmd and phpcbf qa tests
- Loading branch information
1 parent
093091d
commit 00962f4
Showing
4 changed files
with
79 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?xml version="1.0"?> | ||
<ruleset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
name="PHPCS ruleset" | ||
xsi:noNamespaceSchemaLocation="https://raw.githubusercontent.com/squizlabs/PHP_CodeSniffer/master/phpcs.xsd" | ||
> | ||
<description>Test Classes and Tests. Config optimized for local CLO and CI/CD.</description> | ||
|
||
<rule ref="PSR12"/> | ||
|
||
<file>Classes</file> | ||
|
||
<arg name="extensions" value="php" /> | ||
<arg name="basepath" value="."/> | ||
<arg name="colors"/> | ||
<arg name="parallel" value="75"/> | ||
<arg value="nps"/> | ||
</ruleset> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?xml version="1.0"?> | ||
<ruleset name="PHPMD ruleset" | ||
xmlns="http://pmd.sf.net/ruleset/1.0.0" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://pmd.sf.net/ruleset/1.0.0 http://pmd.sf.net/ruleset_xml_schema.xsd" | ||
xsi:noNamespaceSchemaLocation="http://pmd.sf.net/ruleset_xml_schema.xsd" | ||
> | ||
<description> | ||
Adapted the phpmd default config. | ||
* Import all rule sets | ||
* Allow variables as long as 25 chars | ||
</description> | ||
|
||
<rule ref="rulesets/codesize.xml"/> | ||
<rule ref="rulesets/controversial.xml"> | ||
<exclude name="Superglobals"/> | ||
</rule> | ||
<rule ref="rulesets/design.xml"/> | ||
<rule ref="rulesets/naming.xml"> | ||
<exclude name="LongVariable"/> | ||
</rule> | ||
<rule ref="rulesets/naming.xml/LongVariable"> | ||
<properties> | ||
<property name="maximum" value="26"/> | ||
</properties> | ||
</rule> | ||
<rule ref="rulesets/unusedcode.xml"> | ||
<exclude name="UnusedFormalParameter"/> | ||
</rule> | ||
<rule ref="rulesets/cleancode.xml"> | ||
<exclude name="StaticAccess"/> | ||
<exclude name="ElseExpression"/> | ||
<exclude name="LongVariable"/> | ||
</rule> | ||
</ruleset> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters