diff options
| author | andyst <andy.st@gmail.com> | 2009-06-01 23:45:37 -0700 | 
|---|---|---|
| committer | andyst <andy.st@gmail.com> | 2009-06-01 23:45:37 -0700 | 
| commit | 02a840c84cada5a1c0cc0768f350424460310e5d (patch) | |
| tree | 6a35d4afddcf291327a4ff42245bca17328084ae /index.php | |
| parent | d0845aadc629cf10b8eee490a651c039750a1430 (diff) | |
| parent | 3b6567f38c206f1302c7b22d94d5eae4b458311a (diff) | |
Merge branch 'master' of git@github.com:gallery/gallery3
Diffstat (limited to 'index.php')
| -rw-r--r-- | index.php | 17 | 
1 files changed, 11 insertions, 6 deletions
| @@ -27,7 +27,7 @@ version_compare(PHP_VERSION, '5.2.3', '<') and exit('Gallery requires PHP 5.2.3  !ini_get('short_open_tag') and exit('Gallery requires short_open_tag to be on.');  // Set the error reporting level.  Use E_ALL unless you have a special need. -error_reporting(E_NONE); +error_reporting(0);  // Disabling display_errors will  effectively disable Kohana error display  // and logging. You can turn off Kohana errors in application/config/config.php @@ -48,11 +48,16 @@ define('SYSPATH', strtr(realpath('system') . '/', DIRECTORY_SEPARATOR, '/'));  // Force a test run if we're in command line mode.  if (PHP_SAPI == 'cli') { -  array_splice($_SERVER['argv'], 1, 0, 'gallery_unit_test'); -  define('TEST_MODE', 1); -  @mkdir('test/var/logs', 0777, true); -  define('VARPATH', strtr(realpath('test/var') . '/', DIRECTORY_SEPARATOR, '/')); -  @copy("var/database.php", VARPATH . "database.php"); +  if ($_SERVER['argv'][1] != "package") { +    array_splice($_SERVER['argv'], 1, 0, 'gallery_unit_test'); +    define('TEST_MODE', 1); +    @mkdir('test/var/logs', 0777, true); +    define('VARPATH', strtr(realpath('test/var') . '/', DIRECTORY_SEPARATOR, '/')); +    @copy("var/database.php", VARPATH . "database.php"); +  } else { +    define('TEST_MODE', 0); +    define('VARPATH', strtr(realpath('var') . '/', DIRECTORY_SEPARATOR, '/')); +  }  } else {    define('TEST_MODE', 0);    define('VARPATH', strtr(realpath('var') . '/', DIRECTORY_SEPARATOR, '/')); | 
