From 53664787d459066eaf26a3dec1df7c25eddcc912 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Wed, 3 Dec 2008 06:00:30 +0000 Subject: Add a filter to unit tests. Now you can do 'php index.php Album_Helper_Test Photo_Helper_Test' to just run those two --- index.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'index.php') diff --git a/index.php b/index.php index 44b00e67..938eb448 100644 --- a/index.php +++ b/index.php @@ -47,7 +47,7 @@ define('SYSPATH', strtr(realpath('kohana') . '/', DIRECTORY_SEPARATOR, '/')); // Force a test run if we're in command line mode. if (PHP_SAPI == 'cli') { - $_SERVER['argv'] = array($_SERVER['argv'][0], 'gallery_unit_test'); + array_splice($_SERVER['argv'], 1, 0, 'gallery_unit_test'); define('TEST_MODE', 1); @system('mkdir -p test/var/logs'); define('VARPATH', strtr(realpath('test/var') . '/', DIRECTORY_SEPARATOR, '/')); -- cgit v1.2.3