mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-05-20 03:19:13 -04:00
Add a filter to unit tests. Now you can do 'php index.php Album_Helper_Test Photo_Helper_Test' to just run those two
This commit is contained in:
@@ -64,6 +64,10 @@ class Unit_Test_Core {
|
||||
// The class name should be the same as the file name
|
||||
$class = substr($path, strrpos($path, '/') + 1, -(strlen(EXT)));
|
||||
|
||||
if (count($_SERVER['argv']) > 2 && !in_array($class, $_SERVER['argv'])) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// Skip hidden files
|
||||
if (substr($class, 0, 1) === '.')
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user