diff options
Diffstat (limited to 'tests/classloader.php')
-rw-r--r-- | tests/classloader.php | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/classloader.php b/tests/classloader.php index a576eb8d0..648b7432d 100644 --- a/tests/classloader.php +++ b/tests/classloader.php @@ -37,5 +37,15 @@ spl_autoload_register(function ($className){ if(file_exists($relPath)){ require_once $relPath; } + } else if(strpos($className, 'Test\\') === 0) { + $path = strtolower( + str_replace('\\', '/', substr($className, 4)) . '.php' + ); + echo $path; + $relPath = __DIR__ . '/../../../tests/lib' . $path; + + if(file_exists($relPath)){ + require_once $relPath; + } } });
\ No newline at end of file |