From 19c235a5bf27c4bb884c753deee7b446d57ecfda Mon Sep 17 00:00:00 2001 From: Sam Minnee Date: Sat, 27 Jun 2009 06:29:12 +0000 Subject: [PATCH] BUGFIX #3433: Fixed test runner PHPUnit detection on an instance with trailing slashes in paths git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@80215 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- dev/TestRunner.php | 1 + 1 file changed, 1 insertion(+) diff --git a/dev/TestRunner.php b/dev/TestRunner.php index 344ac5759..7ec5179c5 100644 --- a/dev/TestRunner.php +++ b/dev/TestRunner.php @@ -8,6 +8,7 @@ function hasPhpUnit() { $paths = explode(PATH_SEPARATOR, ini_get('include_path')); foreach($paths as $path) { + if(substr($path,-1) == DIRECTORY_SEPARATOR) $path = substr($path,0,-1); if(@file_exists("$path/PHPUnit/Framework.php")) return true; } return false;