phpcs.xml.dist 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <?xml version="1.0"?>
  2. <ruleset>
  3. <arg name="basepath" value="."/>
  4. <arg name="extensions" value="php"/>
  5. <arg name="parallel" value="80"/>
  6. <arg name="cache" value=".phpcs-cache"/>
  7. <arg name="colors" />
  8. <!-- Ignore warnings and show progress of the run -->
  9. <arg value="nps"/>
  10. <file>lib</file>
  11. <file>tests</file>
  12. <rule ref="Doctrine">
  13. <!-- Traversable type hints often end up as mixed[], so we skip them for now -->
  14. <exclude name="SlevomatCodingStandard.TypeHints.PropertyTypeHint.MissingTraversableTypeHintSpecification"/>
  15. <exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingTraversableTypeHintSpecification"/>
  16. <exclude name="SlevomatCodingStandard.TypeHints.ReturnTypeHint.MissingTraversableTypeHintSpecification"/>
  17. <!-- Will cause BC breaks to method signatures - disabled for now -->
  18. <exclude name="SlevomatCodingStandard.TypeHints.ReturnTypeHint.MissingNativeTypeHint"/>
  19. <exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint"/>
  20. </rule>
  21. <!-- Property type hints are only available in PHP 7.4+ -->
  22. <rule ref="SlevomatCodingStandard.TypeHints.PropertyTypeHint">
  23. <properties>
  24. <property name="enableNativeTypeHint" value="false"/>
  25. </properties>
  26. </rule>
  27. <rule ref="PSR1.Classes.ClassDeclaration.MultipleClasses">
  28. <exclude-pattern>tests/*</exclude-pattern>
  29. </rule>
  30. <rule ref="SlevomatCodingStandard.Classes.SuperfluousAbstractClassNaming">
  31. <exclude-pattern>lib/Doctrine/Common/DataFixtures/AbstractFixture.php</exclude-pattern>
  32. <exclude-pattern>lib/Doctrine/Common/DataFixtures/Executor/AbstractExecutor.php</exclude-pattern>
  33. </rule>
  34. <rule ref="SlevomatCodingStandard.Classes.SuperfluousExceptionNaming">
  35. <exclude-pattern>lib/Doctrine/Common/DataFixtures/Exception/CircularReferenceException.php</exclude-pattern>
  36. </rule>
  37. <rule ref="SlevomatCodingStandard.Classes.SuperfluousInterfaceNaming">
  38. <exclude-pattern>lib/Doctrine/Common/DataFixtures/DependentFixtureInterface.php</exclude-pattern>
  39. <exclude-pattern>lib/Doctrine/Common/DataFixtures/FixtureInterface.php</exclude-pattern>
  40. <exclude-pattern>lib/Doctrine/Common/DataFixtures/Purger/ORMPurgerInterface.php</exclude-pattern>
  41. <exclude-pattern>lib/Doctrine/Common/DataFixtures/Purger/PurgerInterface.php</exclude-pattern>
  42. <exclude-pattern>lib/Doctrine/Common/DataFixtures/OrderedFixtureInterface.php</exclude-pattern>
  43. <exclude-pattern>lib/Doctrine/Common/DataFixtures/SharedFixtureInterface.php</exclude-pattern>
  44. </rule>
  45. <rule ref="Squiz.Classes.ClassFileName.NoMatch">
  46. <exclude-pattern>tests/*</exclude-pattern>
  47. </rule>
  48. </ruleset>