add Traits to codesniffer
authorStricted <info@stricted.de>
Wed, 10 Jun 2015 17:07:09 +0000 (19:07 +0200)
committerStricted <info@stricted.de>
Wed, 10 Jun 2015 17:07:09 +0000 (19:07 +0200)
CodeSniff/WCF/Sniffs/Classes/ClassFileNameSniff.php
CodeSniff/WCF/ruleset.xml

index 49973829196a9068f8bcb5f3b9b2badd0c884846..6a531188d3284f21fb676583c7a8ddaf755f5687 100644 (file)
@@ -20,6 +20,7 @@ class WCF_Sniffs_Classes_ClassFileNameSniff implements PHP_CodeSniffer_Sniff {
                return array(
                        T_CLASS,
                        T_INTERFACE,
+                       T_TRAIT,
                );
        }
        
index 411c89a0aba07cdbece3420e92dfa43edfa9479c..8c7fb0a697dbf67734eb0399967ee18281ec20de 100644 (file)
@@ -14,6 +14,7 @@
        <rule ref="Generic.Files.EndFileNewline" />
        <rule ref="Generic.Files.OneClassPerFile" />
        <rule ref="Generic.Files.OneInterfacePerFile" />
+       <rule ref="Generic.Files.OneTraitPerFile" />
        <rule ref="Generic.Formatting.DisallowMultipleStatements" />
        <rule ref="Generic.Functions.FunctionCallArgumentSpacing" />
        <rule ref="Generic.NamingConventions.UpperCaseConstantName" />