diff --git a/php/phpunit.php b/php/phpunit.php index 11e4a33..9a20a1f 100755 --- a/php/phpunit.php +++ b/php/phpunit.php @@ -11,12 +11,15 @@ if (!preg_match('@\.php$@', $file)) { continue; } - if (preg_match('@\.test\.php$@', $file)) { + if (preg_match('@(?:\.test|Test)\.php$@', $file)) { $test = $file; } else { $test = preg_replace('@\.php$@', '.test.php', $file); if (!file_exists($test)) { - continue; + $test = 'tests/' . preg_replace('@\.php$@', 'Test.php', $file); + if (!file_exists($test)) { + continue; + } } }