From b5bd96b07b022bfd40d1f38a89350affad22d42d Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Thu, 30 Apr 2009 23:52:55 +0000 Subject: [PATCH] ENHANCEMENT Running TestRunner tests suites alphabetically through natcasesort() instead of using the (relatively arbitrary) class ordering from ClassInfo::getSubclassesFor() git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@75793 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- dev/TestRunner.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dev/TestRunner.php b/dev/TestRunner.php index 32b467368..7773935a9 100644 --- a/dev/TestRunner.php +++ b/dev/TestRunner.php @@ -150,6 +150,7 @@ class TestRunner extends Controller { // run tests before outputting anything to the client $suite = new PHPUnit_Framework_TestSuite(); + natcasesort($classList); foreach($classList as $className) { // Ensure that the autoloader pulls in the test class, as PHPUnit won't know how to do this. class_exists($className); @@ -165,7 +166,7 @@ class TestRunner extends Controller { self::$default_reporter->writeHeader("Sapphire Test Runner"); if (count($classList) > 1) { - self::$default_reporter->writeInfo("All Tests", "Running test cases: " . implode(", ", $classList)); + self::$default_reporter->writeInfo("All Tests", "Running test cases: " . implode(",", $classList)); } else { self::$default_reporter->writeInfo($classList[0], ""); }