Skip to content

Commit

Permalink
Generic/SpreadOperatorSpacingAfter: rename unit test case file to all…
Browse files Browse the repository at this point in the history
…ow for adding more
  • Loading branch information
biinari committed Jul 13, 2024
1 parent 27678e7 commit a791025
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,29 @@ final class SpreadOperatorSpacingAfterUnitTest extends AbstractSniffUnitTest
* The key of the array should represent the line number and the value
* should represent the number of errors that should occur on that line.
*
* @param string $testFile The name of the file being tested.
*
* @return array<int, int>
*/
public function getErrorList()
public function getErrorList($testFile='')
{
return [
12 => 1,
13 => 1,
20 => 2,
40 => 1,
41 => 1,
46 => 2,
60 => 1,
61 => 1,
66 => 2,
];
switch ($testFile) {
case 'SpreadOperatorSpacingAfterUnitTest.1.inc':
return [
12 => 1,
13 => 1,
20 => 2,
40 => 1,
41 => 1,
46 => 2,
60 => 1,
61 => 1,
66 => 2,
];

default:
return [];
}//end switch

}//end getErrorList()

Expand Down

0 comments on commit a791025

Please sign in to comment.