From: foobar Date: Tue, 23 Oct 2001 11:11:29 +0000 (+0000) Subject: Fix these to give correct results even if register_globals=off or X-Git-Tag: POST_PARAMETER_PARSING_API~29 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=76fcdc1afbfa34c2de136d83172bec91b1891ed2;p=php Fix these to give correct results even if register_globals=off or register_argc_argv=off. --- diff --git a/run-tests.php b/run-tests.php index b7417da4bd..8e11e5dbef 100755 --- a/run-tests.php +++ b/run-tests.php @@ -25,6 +25,8 @@ * - do not test PEAR components if base class and/or component class cannot be instanciated */ +set_time_limit(0); + ob_implicit_flush(); define('TEST_PASSED', 0); @@ -43,7 +45,12 @@ if ($opts['help']) { exit; } */ -do_testing($argc, $argv); + +if(!isset($_SERVER['argc'])) { + echo "\nWARNING: register_argc_argv seems to be set 'off' in php.ini\n\n"; +} + +@do_testing($_SERVER['argc'], $_SERVER['argv']); exit; @@ -97,7 +104,7 @@ function create_found_tests_4_modules_list() { function create_modules_2_test_list() { global $compiled_in_modules,$modules_2_test,$modules_available; foreach ($compiled_in_modules AS $value) - if ($modules_2_test[$value]) $modules_available[]=$value; + if (isset($modules_2_test[$value])) $modules_available[]=$value; } diff --git a/tests/basic/011.phpt b/tests/basic/011.phpt index 7c2d395b9d..9320c16c16 100644 --- a/tests/basic/011.phpt +++ b/tests/basic/011.phpt @@ -1,12 +1,20 @@ --TEST-- Testing $argc and $argv handling +--SKIPIF-- + --POST-- --GET-- ab+cd+ef+123+test --FILE-- --EXPECT--