You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I'm new to CodeSniffer and I was hoping to get a good understanding as to why this error keep occurring on existing and new code. The error is Class name "" is not in camel caps format and it happens using PSR1.
phpcs --standard=PSR1 '/var/www/webroot/paypalipn/Test/CodeSniffer/Test.php'
FILE: /private/var/www/webroot/paypalipn/Test/CodeSniffer/Test.php
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
15 | ERROR | Class name "" is not in camel caps format
----------------------------------------------------------------------
Time: 9ms; Memory: 2.5Mb
phpcbf --standard=PSR1 --encoding=utf-8 -w -v -a -s '/var/www/webroot/paypalipn/Test/CodeSniffer/Test.php'
Changing into directory /private/var/www/webroot/paypalipn/Test/CodeSniffer
Processing Test.php [PHP => 97 tokens in 22 lines]... DONE in 8ms (0 fixable violations)
No fixable errors were found
Time: 12ms; Memory: 2.25Mb
A more verbose run:
phpcs --standard=PSR1 --encoding=utf-8 -w -v -a -s '/var/www/webroot/paypalipn/Test/CodeSniffer/Test.php'
Registering sniffs in the PSR1 standard... DONE (7 sniffs registered)
Creating file list... DONE (1 files in queue)
Changing into directory /private/var/www/webroot/paypalipn/Test/CodeSniffer
Processing Test.php [PHP => 97 tokens in 22 lines]... DONE in 5ms (1 errors, 0 warnings)
FILE: /private/var/www/webroot/paypalipn/Test/CodeSniffer/Test.php
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
15 | ERROR | Class name "" is not in camel caps format
| | (Squiz.Classes.ValidClassName.NotCamelCaps)
----------------------------------------------------------------------
The text was updated successfully, but these errors were encountered:
gsherwood
changed the title
Class name "" is not in camel caps format PRS1
No space after class name generates: Class name "" is not in camel caps format
Jul 31, 2015
This was caused by a specific sniff assuming there would be a space between the class name and the opening brace, which is obviously not the case in your code. I've now fixed this bug.
So I'm new to CodeSniffer and I was hoping to get a good understanding as to why this error keep occurring on existing and new code. The error is Class name "" is not in camel caps format and it happens using PSR1.
FILE CONTENT:
A more verbose run:
The text was updated successfully, but these errors were encountered: