[limb-svn] r6489 - in 3.x/trunk/limb/tests_runner: src tests/cases

svn at limb-project.com svn at limb-project.com
Tue Nov 6 13:59:47 MSK 2007


Author: pachanga
Date: 2007-11-06 13:59:46 +0300 (Tue, 06 Nov 2007)
New Revision: 6489
URL: http://fisheye.limb-project.com/changelog/limb/?cs=6489

Modified:
   3.x/trunk/limb/tests_runner/src/lmbTestShellUI.class.php
   3.x/trunk/limb/tests_runner/tests/cases/lmbTestShellUITest.class.php
Log:
-- adding short -M alias for --methods
-- better help message
-- some minor improvements


Modified: 3.x/trunk/limb/tests_runner/src/lmbTestShellUI.class.php
===================================================================
--- 3.x/trunk/limb/tests_runner/src/lmbTestShellUI.class.php	2007-11-05 07:54:28 UTC (rev 6488)
+++ 3.x/trunk/limb/tests_runner/src/lmbTestShellUI.class.php	2007-11-06 10:59:46 UTC (rev 6489)
@@ -61,16 +61,18 @@
 Arguments:
   <file|dir> [<file1|dir1>, ... <fileN|dirN>] - a list of files/directories, globs are supported(e.g. '*')
 Options:
-  -h, --help                      Displays this help and exit
-  -c, --config=/file.php          PHP configuration file path
-  -I, --include='filter1;filter2' Sets file filters used for including test files during
-                                  recursive traversal of directories.
-                                  '*Test.class.php;*test.php;*Test.php' by default.
-  -C, --cover=path1;path2         Sets paths delimitered with ';' which should be analyzed
-                                  for test coverage(requires XDebug extension!)
-  --cover-report=dir              Sets coverage report directory
-  --cover-exclude=path1;path2     Sets paths delimitered with ';' which should be excluded
-                                  from coverage analysis
+  -h, --help                        Displays this help and exit
+  -c, --config=/file.php            PHP configuration file path
+  -I, --include='filter1;filter2'   Sets file filters used for including test files during
+                                    recursive traversal of directories.
+                                    '*Test.class.php;*test.php;*Test.php' by default.
+  -M, --methods=testFoo[,testBar]   Comma separated list of test methods which should be
+                                    executed 
+  -C, --cover=path1;path2           Sets paths delimitered with ';' which should be analyzed
+                                    for test coverage(requires XDebug extension!)
+  --cover-report=dir                Sets coverage report directory
+  --cover-exclude=path1;path2       Sets paths delimitered with ';' which should be excluded
+                                    from coverage analysis
 
 $version
 
@@ -111,7 +113,7 @@
 
   static function getShortOpts()
   {
-    return 'hvI:c:C:';
+    return 'hvI:c:C:M:';
   }
 
   static function getLongOpts()
@@ -190,8 +192,9 @@
         case '--cover-exclude':
           $cover_exclude = $option[1];
           break;
+        case 'M':
         case '--methods':
-          lmbTestOptions :: set('methods_filter', explode(',', $option[1]));
+          lmbTestOptions :: set('methods_filter', array_map('trim', explode(',', trim($option[1]))));
           break;
       }
     }

Modified: 3.x/trunk/limb/tests_runner/tests/cases/lmbTestShellUITest.class.php
===================================================================
--- 3.x/trunk/limb/tests_runner/tests/cases/lmbTestShellUITest.class.php	2007-11-05 07:54:28 UTC (rev 6488)
+++ 3.x/trunk/limb/tests_runner/tests/cases/lmbTestShellUITest.class.php	2007-11-06 10:59:46 UTC (rev 6489)
@@ -131,7 +131,7 @@
   {
     if(!extension_loaded('xdebug'))
     {
-      echo "Skipping coverage test since xdebug is not loaded";
+      echo "Skipping coverage test since xdebug is not loaded\n";
       return;
     }
     $this->_createTestCase($f = LIMB_VAR_DIR . '/cases/cover_test.php');



More information about the limb-svn mailing list