Skip to content

Commit

Permalink
Sniff test: adjust two test files to match
Browse files Browse the repository at this point in the history
This removes two expected errors due to the tokenizer change made in the previous commit.

### `Generic.Arrays.DisallowLongArraySyntax`

The code on line 13 is a parse error, so the sniff no longer throwing an error for it should not be our concern.
```php
$var = array;
```

### `Squiz.PHP.CommentedOutCode`

The code which triggered the warning on line 35 was a docblock written as a block comment and not really commented out code anyway, so this could be considered a fix for a false positive.
```php
/*
 * The listeners array.
 *
 * @var array(PHP_CodeSniffer_Sniff)
 */
```
  • Loading branch information
jrfnl committed May 27, 2021
1 parent 964a38c commit a6daa05
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ public function getErrorList($testFile='')
6 => 1,
7 => 1,
12 => 1,
13 => 1,
];
case 'DisallowLongArraySyntaxUnitTest.2.inc':
return [
Expand Down
1 change: 0 additions & 1 deletion src/Standards/Squiz/Tests/PHP/CommentedOutCodeUnitTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ public function getWarningList($testFile='CommentedOutCodeUnitTest.inc')
8 => 1,
15 => 1,
19 => 1,
35 => 1,
87 => 1,
91 => 1,
97 => 1,
Expand Down

0 comments on commit a6daa05

Please sign in to comment.