MDL-32323 fix PHPUNIT_UTIL constant usage

This commit is contained in:
Petr Skoda
2012-04-10 15:27:06 +02:00
parent 94a994b4fc
commit 2fde539255
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -83,6 +83,7 @@ if ($options['run']) {
foreach ($_SERVER['argv'] as $k=>$v) {
if (strpos($v, '--run') === 0 or strpos($v, '--phpunitdir') === 0) {
unset($_SERVER['argv'][$k]);
$_SERVER['argc'] = $_SERVER['argc'] - 1;
}
}
$_SERVER['argv'] = array_values($_SERVER['argv']);
+1 -1
View File
@@ -58,7 +58,7 @@ function phpunit_bootstrap_error($errorcode, $text = '') {
$text = 'Unknown error '.$errorcode.$text;
break;
}
if (PHPUNIT_UTIL) {
if (defined('PHPUNIT_UTIL') and PHPUNIT_UTIL) {
// do not write to error stream because we need the error message in PHP exec from web ui
echo($text."\n");
} else {