[limb-svn] r6023 - 3.x/trunk/limb/tests_runner/src
svn at limb-project.com
svn at limb-project.com
Thu Jun 28 18:01:23 MSD 2007
Author: pachanga
Date: 2007-06-28 18:01:23 +0400 (Thu, 28 Jun 2007)
New Revision: 6023
URL: http://fisheye.limb-project.com/changelog/limb/?cs=6023
Modified:
3.x/trunk/limb/tests_runner/src/lmbTestRunner.class.php
3.x/trunk/limb/tests_runner/src/lmbTestTreeGlobNode.class.php
Log:
-- lmbTestTreeGlobNode throws exception if no files were found
-- lmbTestRunner doesn't catch exception, lmbTestShellUI does a better job in this case
Modified: 3.x/trunk/limb/tests_runner/src/lmbTestRunner.class.php
===================================================================
--- 3.x/trunk/limb/tests_runner/src/lmbTestRunner.class.php 2007-06-28 13:35:51 UTC (rev 6022)
+++ 3.x/trunk/limb/tests_runner/src/lmbTestRunner.class.php 2007-06-28 14:01:23 UTC (rev 6023)
@@ -43,15 +43,7 @@
$this->_startTimer();
$this->_startCoverage();
- try
- {
- $res = $this->_doRun($root_node, $path);
- }
- catch(Exception $e)
- {
- $this->_showException($e);
- return false;
- }
+ $res = $this->_doRun($root_node, $path);
$this->_endCoverage();
$this->_stopTimer();
@@ -67,11 +59,6 @@
return $test->run($this->_getReporter());
}
- protected function _showException($e)
- {
- echo $e->__toString();
- }
-
protected function _startTimer()
{
$this->start_time = microtime(true);
Modified: 3.x/trunk/limb/tests_runner/src/lmbTestTreeGlobNode.class.php
===================================================================
--- 3.x/trunk/limb/tests_runner/src/lmbTestTreeGlobNode.class.php 2007-06-28 13:35:51 UTC (rev 6022)
+++ 3.x/trunk/limb/tests_runner/src/lmbTestTreeGlobNode.class.php 2007-06-28 14:01:23 UTC (rev 6023)
@@ -28,11 +28,18 @@
protected function _loadChildren()
{
+ $found = false;
foreach($this->paths as $path)
{
foreach(glob($path) as $item)
+ {
+ $found = true;
$this->addChild(new lmbTestTreeFilePathNode($item));
+ }
}
+
+ if(!$found)
+ throw new Exception("No tests were found for path '" . implode(';', $this->paths) . "'!");
}
function getTestLabel()
More information about the limb-svn
mailing list