[limb-svn] r6854 - in 3.x/trunk/limb: . cache/tests/cases cli/tests/cases fs/tests/cases i18n/tests/cases js/tests/cases view/tests/cases web_cache/tests/cases

svn at limb-project.com svn at limb-project.com
Sun Mar 23 20:07:36 MSK 2008


Author: pachanga
Date: 2008-03-23 20:07:36 +0300 (Sun, 23 Mar 2008)
New Revision: 6854
URL: http://fisheye.limb-project.com/changelog/limb/?cs=6854

Modified:
   3.x/trunk/limb/cache/tests/cases/.setup.php
   3.x/trunk/limb/cli/tests/cases/.setup.php
   3.x/trunk/limb/fs/tests/cases/.setup.php
   3.x/trunk/limb/i18n/tests/cases/.setup.php
   3.x/trunk/limb/js/tests/cases/.setup.php
   3.x/trunk/limb/runtests.php
   3.x/trunk/limb/view/tests/cases/.setup.php
   3.x/trunk/limb/web_cache/tests/cases/.setup.php
Log:
-- adding automatic LIMB_VAR_DIR creation and definition during tests

Modified: 3.x/trunk/limb/cache/tests/cases/.setup.php
===================================================================
--- 3.x/trunk/limb/cache/tests/cases/.setup.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/cache/tests/cases/.setup.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -1,3 +1,9 @@
 <?php
+if(!defined('LIMB_VAR_DIR'))
+{
+  @define('LIMB_VAR_DIR', dirname(__FILE__) . '/../../../var');
+  if(!is_dir(LIMB_VAR_DIR) && !mkdir(LIMB_VAR_DIR))
+    throw new Exception("Could not create LIMB_VAR_DIR at '" . LIMB_VAR_DIR . "' during tests execution");
+}
+
 require_once(dirname(__FILE__) . '/../../common.inc.php');
-?>

Modified: 3.x/trunk/limb/cli/tests/cases/.setup.php
===================================================================
--- 3.x/trunk/limb/cli/tests/cases/.setup.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/cli/tests/cases/.setup.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -1,4 +1,10 @@
 <?php
+if(!defined('LIMB_VAR_DIR'))
+{
+  @define('LIMB_VAR_DIR', dirname(__FILE__) . '/../../../var');
+  if(!is_dir(LIMB_VAR_DIR) && !mkdir(LIMB_VAR_DIR))
+    throw new Exception("Could not create LIMB_VAR_DIR at '" . LIMB_VAR_DIR . "' during tests execution");
+}
 
 require_once(dirname(__FILE__) . '/../../common.inc.php');
 

Modified: 3.x/trunk/limb/fs/tests/cases/.setup.php
===================================================================
--- 3.x/trunk/limb/fs/tests/cases/.setup.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/fs/tests/cases/.setup.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -1,4 +1,11 @@
 <?php
+if(!defined('LIMB_VAR_DIR'))
+{
+  @define('LIMB_VAR_DIR', dirname(__FILE__) . '/../../../var');
+  if(!is_dir(LIMB_VAR_DIR) && !mkdir(LIMB_VAR_DIR))
+    throw new Exception("Could not create LIMB_VAR_DIR at '" . LIMB_VAR_DIR . "' during tests execution");
+}
+
 require_once(dirname(__FILE__) . '/../../common.inc.php');
 
 

Modified: 3.x/trunk/limb/i18n/tests/cases/.setup.php
===================================================================
--- 3.x/trunk/limb/i18n/tests/cases/.setup.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/i18n/tests/cases/.setup.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -1,4 +1,10 @@
 <?php
+if(!defined('LIMB_VAR_DIR'))
+{
+  @define('LIMB_VAR_DIR', dirname(__FILE__) . '/../../../var');
+  if(!is_dir(LIMB_VAR_DIR) && !mkdir(LIMB_VAR_DIR))
+    throw new Exception("Could not create LIMB_VAR_DIR at '" . LIMB_VAR_DIR . "' during tests execution");
+}
+
 require_once(dirname(__FILE__) . '/../../common.inc.php');
 require_once('limb/i18n/src/charset/driver.inc.php');
-?>

Modified: 3.x/trunk/limb/js/tests/cases/.setup.php
===================================================================
--- 3.x/trunk/limb/js/tests/cases/.setup.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/js/tests/cases/.setup.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -1,4 +1,11 @@
 <?php
+if(!defined('LIMB_VAR_DIR'))
+{
+  @define('LIMB_VAR_DIR', dirname(__FILE__) . '/../../../var');
+  if(!is_dir(LIMB_VAR_DIR) && !mkdir(LIMB_VAR_DIR))
+    throw new Exception("Could not create LIMB_VAR_DIR at '" . LIMB_VAR_DIR . "' during tests execution");
+}
+
 require_once(dirname(__FILE__) . '/../../common.inc.php');
 
 @define('LIMB_JS_INCLUDE_PATH', rtrim(LIMB_VAR_DIR, '/\\'));

Modified: 3.x/trunk/limb/runtests.php
===================================================================
--- 3.x/trunk/limb/runtests.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/runtests.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -17,7 +17,9 @@
   foreach($packages as $pkg)
   {
     $runner = new lmbTestRunner();
-    $res &= $runner->run(new lmbTestTreeDirNode(dirname(__FILE__) . '/' . $pkg . '/tests/cases/'));
+    $path = dirname(__FILE__) . '/' . $pkg . '/tests/cases/';
+    if(is_dir($path))
+      $res &= $runner->run(new lmbTestTreeDirNode($path));
   }
 }
 else

Modified: 3.x/trunk/limb/view/tests/cases/.setup.php
===================================================================
--- 3.x/trunk/limb/view/tests/cases/.setup.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/view/tests/cases/.setup.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -1,4 +1,10 @@
 <?php
+if(!defined('LIMB_VAR_DIR'))
+{
+  @define('LIMB_VAR_DIR', dirname(__FILE__) . '/../../../var');
+  if(!is_dir(LIMB_VAR_DIR) && !mkdir(LIMB_VAR_DIR))
+    throw new Exception("Could not create LIMB_VAR_DIR at '" . LIMB_VAR_DIR . "' during tests execution");
+}
 require_once(dirname(__FILE__) . '/../../common.inc.php');
 lmb_require('limb/view/tests/lmbWactTestCase.class.php');
 

Modified: 3.x/trunk/limb/web_cache/tests/cases/.setup.php
===================================================================
--- 3.x/trunk/limb/web_cache/tests/cases/.setup.php	2008-03-23 16:52:58 UTC (rev 6853)
+++ 3.x/trunk/limb/web_cache/tests/cases/.setup.php	2008-03-23 17:07:36 UTC (rev 6854)
@@ -1,4 +1,11 @@
 <?php
+if(!defined('LIMB_VAR_DIR'))
+{
+  @define('LIMB_VAR_DIR', dirname(__FILE__) . '/../../../var');
+  if(!is_dir(LIMB_VAR_DIR) && !mkdir(LIMB_VAR_DIR))
+    throw new Exception("Could not create LIMB_VAR_DIR at '" . LIMB_VAR_DIR . "' during tests execution");
+}
+
 require_once(dirname(__FILE__) . '/../../common.inc.php');
 
 



More information about the limb-svn mailing list