File tree Expand file tree Collapse file tree 3 files changed +12
-101
lines changed
testsuite/Magento/Test/Integrity
lib/internal/Magento/Framework/TestFramework/Test/Unit/Unit/Helper Expand file tree Collapse file tree 3 files changed +12
-101
lines changed Original file line number Diff line number Diff line change 9
9
$ testsBaseDir = $ baseDir . '/dev/tests/static ' ;
10
10
$ autoloadWrapper = \Magento \Framework \Autoload \AutoloaderRegistry::getAutoloader ();
11
11
$ autoloadWrapper ->addPsr4 ('Magento \\' , $ testsBaseDir . '/testsuite/Magento/ ' );
12
- $ autoloadWrapper ->addPsr4 ('Magento \\TestFramework \\' , $ testsBaseDir . '/framework/Magento/TestFramework/ ' );
12
+ $ autoloadWrapper ->addPsr4 (
13
+ 'Magento \\TestFramework \\' ,
14
+ [
15
+ $ testsBaseDir . '/framework/Magento/TestFramework/ ' ,
16
+ $ testsBaseDir . '/../integration/framework/Magento/TestFramework/ ' ,
17
+ ]
18
+ );
13
19
$ autoloadWrapper ->addPsr4 ('Magento \\' , $ baseDir . '/var/generation/Magento/ ' );
Original file line number Diff line number Diff line change @@ -557,7 +557,9 @@ public function testCoversAnnotation()
557
557
}
558
558
}
559
559
if ($ errors ) {
560
- $ this ->fail (implode (PHP_EOL , $ errors ));
560
+ $ this ->fail ('Nonexistent classes/methods were found in @covers annotations: ' . PHP_EOL
561
+ . implode (PHP_EOL , $ errors )
562
+ );
561
563
}
562
564
}
563
565
@@ -567,8 +569,7 @@ public function testCoversAnnotation()
567
569
*/
568
570
private function isNonexistentEntityCovered ($ matches )
569
571
{
570
- return (!empty ($ matches [2 ]) && !class_exists ($ matches [2 ])
571
- || !empty ($ matches [4 ]) && !method_exists ($ matches [2 ], $ matches [4 ]))
572
- && strpos ($ matches [2 ], 'Magento\TestFramework ' ) === false ; // not autoloaded currently
572
+ return !empty ($ matches [2 ]) && !class_exists ($ matches [2 ])
573
+ || !empty ($ matches [4 ]) && !method_exists ($ matches [2 ], $ matches [4 ]);
573
574
}
574
575
}
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments