Updated Doctrine Coding Standard to 7.0

parent 7f4ef4ac
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "44b68871fc8d7e631feabb7d92727d6c", "content-hash": "a86df18ed2c69e764faef4b786e0326d",
"packages": [ "packages": [
{ {
"name": "doctrine/cache", "name": "doctrine/cache",
...@@ -318,28 +318,28 @@ ...@@ -318,28 +318,28 @@
}, },
{ {
"name": "doctrine/coding-standard", "name": "doctrine/coding-standard",
"version": "6.0.0", "version": "7.0.2",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/doctrine/coding-standard.git", "url": "https://github.com/doctrine/coding-standard.git",
"reference": "d33f69eb98b25aa51ffe3a909f0ec77000af4701" "reference": "d8a60ec4da68025c42795b714f66e277dd3e11de"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/doctrine/coding-standard/zipball/d33f69eb98b25aa51ffe3a909f0ec77000af4701", "url": "https://api.github.com/repos/doctrine/coding-standard/zipball/d8a60ec4da68025c42795b714f66e277dd3e11de",
"reference": "d33f69eb98b25aa51ffe3a909f0ec77000af4701", "reference": "d8a60ec4da68025c42795b714f66e277dd3e11de",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"dealerdirect/phpcodesniffer-composer-installer": "^0.5.0", "dealerdirect/phpcodesniffer-composer-installer": "^0.5.0",
"php": "^7.1", "php": "^7.2",
"slevomat/coding-standard": "^5.0", "slevomat/coding-standard": "^6.0",
"squizlabs/php_codesniffer": "^3.4.0" "squizlabs/php_codesniffer": "^3.5.3"
}, },
"type": "phpcodesniffer-standard", "type": "phpcodesniffer-standard",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-master": "6.0.x-dev" "dev-master": "7.0.x-dev"
} }
}, },
"autoload": { "autoload": {
...@@ -375,7 +375,7 @@ ...@@ -375,7 +375,7 @@
"standard", "standard",
"style" "style"
], ],
"time": "2019-03-15T12:45:47+00:00" "time": "2019-12-11T07:59:21+00:00"
}, },
{ {
"name": "doctrine/instantiator", "name": "doctrine/instantiator",
...@@ -2638,30 +2638,31 @@ ...@@ -2638,30 +2638,31 @@
}, },
{ {
"name": "slevomat/coding-standard", "name": "slevomat/coding-standard",
"version": "5.0.2", "version": "6.1.1",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/slevomat/coding-standard.git", "url": "https://github.com/slevomat/coding-standard.git",
"reference": "223f02b6193fe47b7b483bfa5bf75693535482dd" "reference": "0a7934d7ecdfe402079027513daa3b7e881f315d"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/slevomat/coding-standard/zipball/223f02b6193fe47b7b483bfa5bf75693535482dd", "url": "https://api.github.com/repos/slevomat/coding-standard/zipball/0a7934d7ecdfe402079027513daa3b7e881f315d",
"reference": "223f02b6193fe47b7b483bfa5bf75693535482dd", "reference": "0a7934d7ecdfe402079027513daa3b7e881f315d",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
"php": "^7.1", "php": "^7.1",
"phpstan/phpdoc-parser": "^0.3.1", "phpstan/phpdoc-parser": "0.3.5 - 0.4.2",
"squizlabs/php_codesniffer": "^3.4.0" "squizlabs/php_codesniffer": "^3.5.3"
}, },
"require-dev": { "require-dev": {
"dealerdirect/phpcodesniffer-composer-installer": "0.5.0",
"jakub-onderka/php-parallel-lint": "1.0.0", "jakub-onderka/php-parallel-lint": "1.0.0",
"phing/phing": "2.16.1", "phing/phing": "2.16.2",
"phpstan/phpstan": "0.11.1", "phpstan/phpstan": "0.11.19|0.12.5",
"phpstan/phpstan-phpunit": "0.11", "phpstan/phpstan-phpunit": "0.11.2|0.12.6",
"phpstan/phpstan-strict-rules": "0.11", "phpstan/phpstan-strict-rules": "0.11.1|0.12.1",
"phpunit/phpunit": "8.0.0" "phpunit/phpunit": "7.5.18|8.5.2"
}, },
"type": "phpcodesniffer-standard", "type": "phpcodesniffer-standard",
"autoload": { "autoload": {
...@@ -2674,20 +2675,20 @@ ...@@ -2674,20 +2675,20 @@
"MIT" "MIT"
], ],
"description": "Slevomat Coding Standard for PHP_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.", "description": "Slevomat Coding Standard for PHP_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.",
"time": "2019-03-12T20:26:36+00:00" "time": "2020-01-23T15:37:30+00:00"
}, },
{ {
"name": "squizlabs/php_codesniffer", "name": "squizlabs/php_codesniffer",
"version": "3.5.2", "version": "3.5.3",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/squizlabs/PHP_CodeSniffer.git", "url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
"reference": "65b12cdeaaa6cd276d4c3033a95b9b88b12701e7" "reference": "557a1fc7ac702c66b0bbfe16ab3d55839ef724cb"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/65b12cdeaaa6cd276d4c3033a95b9b88b12701e7", "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/557a1fc7ac702c66b0bbfe16ab3d55839ef724cb",
"reference": "65b12cdeaaa6cd276d4c3033a95b9b88b12701e7", "reference": "557a1fc7ac702c66b0bbfe16ab3d55839ef724cb",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
...@@ -2725,7 +2726,7 @@ ...@@ -2725,7 +2726,7 @@
"phpcs", "phpcs",
"standards" "standards"
], ],
"time": "2019-10-28T04:36:32+00:00" "time": "2019-12-04T04:46:47+00:00"
}, },
{ {
"name": "symfony/console", "name": "symfony/console",
......
<?xml version="1.0"?> <?xml version="1.0"?>
<ruleset> <ruleset
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="vendor/squizlabs/php_codesniffer/phpcs.xsd"
>
<arg name="basepath" value="."/> <arg name="basepath" value="."/>
<arg name="extensions" value="php"/> <arg name="extensions" value="php"/>
<arg name="parallel" value="80"/> <arg name="parallel" value="80"/>
...@@ -18,6 +21,14 @@ ...@@ -18,6 +21,14 @@
<exclude name="SlevomatCodingStandard.Classes.SuperfluousExceptionNaming"/> <exclude name="SlevomatCodingStandard.Classes.SuperfluousExceptionNaming"/>
<exclude name="SlevomatCodingStandard.ControlStructures.ControlStructureSpacing.IncorrectLinesCountAfterLastControlStructure"/> <exclude name="SlevomatCodingStandard.ControlStructures.ControlStructureSpacing.IncorrectLinesCountAfterLastControlStructure"/>
<exclude name="SlevomatCodingStandard.Classes.DisallowLateStaticBindingForConstants.DisallowedLateStaticBindingForConstant"/> <exclude name="SlevomatCodingStandard.Classes.DisallowLateStaticBindingForConstants.DisallowedLateStaticBindingForConstant"/>
<exclude name="Squiz.NamingConventions.ValidVariableName.PublicHasUnderscore"/>
</rule>
<!-- Disable the rules that will require PHP 7.4 -->
<rule ref="SlevomatCodingStandard.TypeHints.PropertyTypeHint">
<properties>
<property name="enableNativeTypeHint" value="false"/>
</properties>
</rule> </rule>
<rule ref="PSR1.Classes.ClassDeclaration.MultipleClasses"> <rule ref="PSR1.Classes.ClassDeclaration.MultipleClasses">
...@@ -36,6 +47,11 @@ ...@@ -36,6 +47,11 @@
<exclude-pattern>tests/Doctrine/Tests/DBAL/Tools/TestAsset/*</exclude-pattern> <exclude-pattern>tests/Doctrine/Tests/DBAL/Tools/TestAsset/*</exclude-pattern>
</rule> </rule>
<!-- https://github.com/slevomat/coding-standard/issues/868 -->
<rule ref="SlevomatCodingStandard.PHP.UselessParentheses.UselessParentheses">
<exclude-pattern>tests/continuousphp/bootstrap.php</exclude-pattern>
</rule>
<!-- see https://github.com/squizlabs/PHP_CodeSniffer/issues/2099 --> <!-- see https://github.com/squizlabs/PHP_CodeSniffer/issues/2099 -->
<rule ref="Squiz.Commenting.FunctionComment.InvalidNoReturn"> <rule ref="Squiz.Commenting.FunctionComment.InvalidNoReturn">
<exclude-pattern>lib/Doctrine/DBAL/Platforms/AbstractPlatform.php</exclude-pattern> <exclude-pattern>lib/Doctrine/DBAL/Platforms/AbstractPlatform.php</exclude-pattern>
...@@ -43,6 +59,24 @@ ...@@ -43,6 +59,24 @@
<exclude-pattern>tests/Doctrine/Tests/DBAL/Platforms/AbstractPlatformTestCase.php</exclude-pattern> <exclude-pattern>tests/Doctrine/Tests/DBAL/Platforms/AbstractPlatformTestCase.php</exclude-pattern>
</rule> </rule>
<!-- see https://github.com/squizlabs/PHP_CodeSniffer/issues/2838 -->
<rule ref="Squiz.Commenting.FunctionComment.SpacingAfter">
<exclude-pattern>lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php</exclude-pattern>
</rule>
<rule ref="Squiz.NamingConventions.ValidVariableName.MemberNotCamelCaps">
<exclude-pattern>tests/Doctrine/Tests/DBAL/Functional/DataAccess/FetchClass.php</exclude-pattern>
</rule>
<!-- https://github.com/squizlabs/PHP_CodeSniffer/issues/2837 -->
<rule ref="Squiz.NamingConventions.ValidVariableName.NotCamelCaps">
<exclude-pattern>lib/Doctrine/DBAL/Driver/IBMDB2/DB2Connection.php</exclude-pattern>
<exclude-pattern>lib/Doctrine/DBAL/SQLParserUtils.php</exclude-pattern>
<exclude-pattern>lib/Doctrine/DBAL/Tools/Dumper.php</exclude-pattern>
<exclude-pattern>tests/Doctrine/Tests/DBAL/Driver/StatementIteratorTest.php</exclude-pattern>
<exclude-pattern>tests/Doctrine/Tests/DBAL/Tools/DumperTest.php</exclude-pattern>
</rule>
<!-- some statement classes close cursor using an empty while-loop --> <!-- some statement classes close cursor using an empty while-loop -->
<rule ref="Generic.CodeAnalysis.EmptyStatement.DetectedWhile"> <rule ref="Generic.CodeAnalysis.EmptyStatement.DetectedWhile">
<exclude-pattern>lib/Doctrine/DBAL/Driver/SQLSrv/SQLSrvStatement.php</exclude-pattern> <exclude-pattern>lib/Doctrine/DBAL/Driver/SQLSrv/SQLSrvStatement.php</exclude-pattern>
...@@ -53,24 +87,11 @@ ...@@ -53,24 +87,11 @@
<exclude-pattern>lib/Doctrine/DBAL/Driver/SQLSrv/SQLSrvStatement.php</exclude-pattern> <exclude-pattern>lib/Doctrine/DBAL/Driver/SQLSrv/SQLSrvStatement.php</exclude-pattern>
</rule> </rule>
<!-- see https://github.com/squizlabs/PHP_CodeSniffer/issues/2165 -->
<rule ref="Squiz.Arrays.ArrayDeclaration.SpaceBeforeComma">
<exclude-pattern>tests/Doctrine/Tests/DBAL/Platforms/OraclePlatformTest.php</exclude-pattern>
<exclude-pattern>tests/Doctrine/Tests/DBAL/SQLParserUtilsTest.php</exclude-pattern>
</rule>
<!-- see https://github.com/doctrine/dbal/issues/3377 --> <!-- see https://github.com/doctrine/dbal/issues/3377 -->
<rule ref="SlevomatCodingStandard.Operators.DisallowEqualOperators.DisallowedNotEqualOperator"> <rule ref="SlevomatCodingStandard.Operators.DisallowEqualOperators.DisallowedNotEqualOperator">
<exclude-pattern>lib/Doctrine/DBAL/Schema/Comparator.php</exclude-pattern> <exclude-pattern>lib/Doctrine/DBAL/Schema/Comparator.php</exclude-pattern>
</rule> </rule>
<!-- see https://github.com/slevomat/coding-standard/issues/737 -->
<rule ref="SlevomatCodingStandard.TypeHints.TypeHintDeclaration.IncorrectReturnTypeHint">
<exclude-pattern>lib/Doctrine/DBAL/Types/ArrayType.php</exclude-pattern>
<exclude-pattern>lib/Doctrine/DBAL/Types/ObjectType.php</exclude-pattern>
<exclude-pattern>tests/Doctrine/Tests/DBAL/Driver/Mysqli/MysqliConnectionTest.php</exclude-pattern>
</rule>
<!-- DB2_AUTOCOMMIT_ON/DB2_AUTOCOMMIT_OFF are of int type but db2_autocommit() incorrectly expects bool, <!-- DB2_AUTOCOMMIT_ON/DB2_AUTOCOMMIT_OFF are of int type but db2_autocommit() incorrectly expects bool,
see https://bugs.php.net/bug.php?id=77591 --> see https://bugs.php.net/bug.php?id=77591 -->
<rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes.DeclareStrictTypesMissing"> <rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes.DeclareStrictTypesMissing">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment