Check for the real namespace separator (\) now that PHP 5.3 is out.
authorChuck Hagenbuch <chuck@horde.org>
Thu, 29 Oct 2009 20:21:35 +0000 (16:21 -0400)
committerChuck Hagenbuch <chuck@horde.org>
Fri, 30 Oct 2009 00:12:38 +0000 (20:12 -0400)
framework/Date_Parser/test/Horde/Date/Parser/AllTests.php
framework/Icalendar/test/Horde/Icalendar/AllTests.php
framework/bin/test_framework

index a4d9c8a..acc75c7 100644 (file)
@@ -25,7 +25,7 @@ class Horde_Date_Parser_AllTests {
     {
         set_include_path(dirname(__FILE__) . '/../../../../lib' . PATH_SEPARATOR . get_include_path());
         if (!spl_autoload_functions()) {
-            spl_autoload_register(create_function('$class', '$filename = str_replace(array(\'::\', \'_\'), \'/\', $class); include "$filename.php";'));
+            spl_autoload_register(create_function('$class', '$filename = str_replace(array(\'\\\', \'_\'), \'/\', $class); include "$filename.php";'));
         }
 
         $suite = new PHPUnit_Framework_TestSuite('Horde Framework - Horde_Date_Parser');
index ded1c08..16e35fb 100644 (file)
@@ -25,7 +25,7 @@ class Horde_Icalendar_AllTests {
     {
         set_include_path(dirname(__FILE__) . '/../../../lib' . PATH_SEPARATOR . get_include_path());
         if (!spl_autoload_functions()) {
-            spl_autoload_register(create_function('$class', '$filename = str_replace(array(\'::\', \'_\'), \'/\', $class); include "$filename.php";'));
+            spl_autoload_register(create_function('$class', '$filename = str_replace(array(\'\\\', \'_\'), \'/\', $class); include "$filename.php";'));
         }
 
         $suite = new PHPUnit_Framework_TestSuite('Horde Framework - Horde_Icalendar');
index 791c95e..31376ea 100755 (executable)
@@ -58,7 +58,7 @@ class horde_test_runner
 
                 $classnames = array($class, $class_notests, $class_horde, $class_horde_notests, $class_pear2, $class_pear2_notests);
                 foreach ($classnames as $classname) {
-                    $classnames[] = str_replace('_', '::', $classname);
+                    $classnames[] = str_replace('_', '\\', $classname);
                 }
 
                 // Look for something with a ::suite() method.