Skip to content

Commit ed8d16a

Browse files
authored
Merge pull request #2 from jrfnl/feature/fix-sniff-namingconventions-properly
Properly comply with PHPCS naming conventions
2 parents 2bcb394 + 212c487 commit ed8d16a

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

phpcs.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<exclude-pattern>*/concept/city-office/*</exclude-pattern>
3535
<exclude-pattern>*/concept/windowing-system/*</exclude-pattern>
3636
</rule>
37-
<rule ref="vendor/slevomat/coding-standard/SlevomatCodingStandard/Sniffs/TypeHints/DeclareStrictTypesSniff.php">
37+
<rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes">
3838
<exclude-pattern>*/.meta/*\.php</exclude-pattern>
3939
<exclude-pattern>*/concept/*</exclude-pattern>
4040
<exclude-pattern>*/hello-world/*</exclude-pattern>
@@ -44,7 +44,7 @@
4444
<property name="spacesCountAroundEqualsSign" value="0" />
4545
</properties>
4646
</rule>
47-
<rule ref="src/Sniffs/StrictTypes/ExplainStrictTypesSniff.php">
47+
<rule ref="src/Exercism/Sniffs/StrictTypes/ExplainStrictTypesSniff.php">
4848
<exclude-pattern>*/*Test\.php</exclude-pattern>
4949
<exclude-pattern>*/.meta/*\.php</exclude-pattern>
5050
<exclude-pattern>src/*</exclude-pattern>

src/Sniffs/StrictTypes/ExplainStrictTypesSniff.php renamed to src/Exercism/Sniffs/StrictTypes/ExplainStrictTypesSniff.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
declare(strict_types=1);
44

5-
namespace Exercism\Sniffs\StrictTypes;
5+
namespace Exercism\Exercism\Sniffs\StrictTypes;
66

77
use PHP_CodeSniffer\Files\File;
88
use PHP_CodeSniffer\Fixer;
@@ -57,7 +57,7 @@ public function process(File $phpcsFile, $stackPtr): void
5757
$phpcsFile->addFixableError(
5858
'Missing explanation of declaration of strict types.',
5959
$stackPtr - 1,
60-
self::class
60+
'Missing'
6161
);
6262
$this->fix();
6363
}

0 commit comments

Comments
 (0)