1414use PHP_CodeSniffer \Filters \Filter ;
1515use PHP_CodeSniffer \Ruleset ;
1616use PHP_CodeSniffer \Tests \Core \Filters \AbstractFilterTestCase ;
17+ use RecursiveArrayIterator ;
1718
1819/**
1920 * Tests for the \PHP_CodeSniffer\Filters\Filter::accept method.
@@ -34,7 +35,7 @@ class AcceptTest extends AbstractFilterTestCase
3435 public static function initializeConfigAndRuleset ()
3536 {
3637 $ standard = __DIR__ .'/ ' .basename (__FILE__ , '.php ' ).'.xml ' ;
37- self ::$ config = new Config (["--standard= $ standard " , " --ignore=*/somethingelse/* " ]);
38+ self ::$ config = new Config (["--standard= $ standard " , ' --ignore=*/somethingelse/* ' , ' --report-width=80 ' ]);
3839 self ::$ ruleset = new Ruleset (self ::$ config );
3940
4041 }//end initializeConfigAndRuleset()
@@ -52,7 +53,7 @@ public static function initializeConfigAndRuleset()
5253 */
5354 public function testExcludePatterns ($ inputPaths , $ expectedOutput )
5455 {
55- $ fakeDI = new \ RecursiveArrayIterator ($ inputPaths );
56+ $ fakeDI = new RecursiveArrayIterator ($ inputPaths );
5657 $ filter = new Filter ($ fakeDI , '/ ' , self ::$ config , self ::$ ruleset );
5758
5859 $ this ->assertEquals ($ expectedOutput , $ this ->getFilteredResultsAsArray ($ filter ));
@@ -67,7 +68,7 @@ public function testExcludePatterns($inputPaths, $expectedOutput)
6768 *
6869 * @return array<string, array<string, array<string>>>
6970 */
70- public function dataExcludePatterns ()
71+ public static function dataExcludePatterns ()
7172 {
7273 $ testCases = [
7374 // Test top-level exclude patterns.
0 commit comments