-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
switch to syde/phpcs.
- Loading branch information
Showing
11 changed files
with
131 additions
and
79 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,23 @@ | ||
<?xml version="1.0"?> | ||
<ruleset> | ||
|
||
<file>./src</file> | ||
<file>./tests</file> | ||
|
||
<arg value="sp"/> | ||
<arg name="colors"/> | ||
<config name="testVersion" value="7.4-"/> | ||
<config name="ignore_warnings_on_exit" value="1"/> | ||
|
||
<rule ref="Inpsyde"> | ||
<exclude name="WordPress.PHP.DevelopmentFunctions.error_log_trigger_error" /> | ||
</rule> | ||
|
||
<rule ref="Inpsyde.CodeQuality.Psr4"> | ||
<properties> | ||
<property | ||
name="psr4" | ||
type="array" | ||
value=" | ||
Inpsyde\Modularity=>src, | ||
Inpsyde\Modularity\Tests=>tests/src, | ||
Inpsyde\Modularity\Tests\Unit=>tests/unit" | ||
/> | ||
</properties> | ||
<rule ref="Syde-Extra"> | ||
<exclude name="SlevomatCodingStandard.Functions.RequireTrailingCommaInCall.MissingTrailingComma" /> | ||
<exclude name="SlevomatCodingStandard.Functions.RequireTrailingCommaInDeclaration.MissingTrailingComma" /> | ||
</rule> | ||
|
||
<rule ref="Inpsyde.CodeQuality.FunctionLength"> | ||
<exclude-pattern>*/tests/*</exclude-pattern> | ||
</rule> | ||
<rule ref="Inpsyde.CodeQuality.ForbiddenPublicProperty"> | ||
<exclude-pattern>*/tests/*</exclude-pattern> | ||
</rule> | ||
<rule ref="WordPress.PHP.DevelopmentFunctions"> | ||
<exclude-pattern>*/tests/*</exclude-pattern> | ||
</rule> | ||
<rule ref="WordPress.PHP.DiscouragedPHPFunctions"> | ||
<exclude-pattern>*/tests/*</exclude-pattern> | ||
</rule> | ||
<rule ref="WordPress.Security.EscapeOutput"> | ||
<exclude-pattern>*/tests/*</exclude-pattern> | ||
</rule> | ||
<rule ref="Squiz.PHP.Eval"> | ||
<exclude-pattern>*/tests/*</exclude-pattern> | ||
</rule> | ||
</ruleset> | ||
<rule ref="SlevomatCodingStandard.Files.TypeNameMatchesFileName"> | ||
<properties> | ||
<property name="rootNamespaces" type="array"> | ||
<element key="src" value="Inpsyde\Modularity" /> | ||
<element key="tests/phpunit/Unit" value="Inpsyde\Modularity\Tests\Unit" /> | ||
</property> | ||
</properties> | ||
</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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
includes: | ||
- vendor/szepeviktor/phpstan-wordpress/extension.neon | ||
parameters: | ||
level: 8 | ||
paths: | ||
- src/ | ||
treatPhpDocTypesAsCertain: false | ||
ignoreErrors: | ||
- '#Trait Inpsyde\\Modularity\\Module\\ModuleClassNameIdTrait is used zero times and is not analysed.#' | ||
# TODO: Check how we can point ABSPATH constant in phpstan to vendor/roots/wordpress-no-content/ | ||
- '#Path in require_once\(\) \".*\" is not a file or it does not exist.#' |
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
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
Oops, something went wrong.