]> granicus.if.org Git - php/commitdiff
Fix 3 tests that didn't adequately specify the .ini settings they rely on
authorRasmus Lerdorf <rasmus@php.net>
Mon, 30 Jun 2003 18:22:53 +0000 (18:22 +0000)
committerRasmus Lerdorf <rasmus@php.net>
Mon, 30 Jun 2003 18:22:53 +0000 (18:22 +0000)
ext/standard/tests/general_functions/getopt.phpt
tests/basic/012.phpt
tests/lang/bug21800.phpt

index 13a4fa558f39f1296b068bb48652cb9a50e41155..e861268459a0a3f815ef92fa6bf7b866382f0a41 100644 (file)
@@ -2,14 +2,14 @@
 getopt
 --ARGS--
 -v -h -d test -m 1234 -t -j
+--INI--
+register_argc_argv=On
+variables_order=GPS
 --SKIPIF--
 <?php
        if (substr(PHP_OS, 0, 3) == 'WIN') {
                die('skip getopt() is currently not available on Windows');
        }
-       if (!ini_get('register_argc_argv')) {
-               die("skip this test needs register_argc_argv to be enabled");
-       }
 ?>
 --FILE--
 <?php
index 7e70f9a018606bc8a6d5c55813ac7ea61fd94f0b..32978532862e9bd2f1eb286edd87c7db0a01d16b 100644 (file)
@@ -4,6 +4,7 @@ Testing $argc and $argv handling (cli)
 <?php if(php_sapi_name()!='cli') echo 'skip'; ?>
 --INI--
 register_argc_argv=1
+variables_order=GPS
 --ARGS--
 ab cd ef 123 test
 --FILE--
index b835425c3d1a43bfba06981caca8351107589bfd..72755e29a5ae064021a1a02a7d4226d8187c874b 100644 (file)
@@ -4,7 +4,8 @@ Bug #21800 (Segfault under interactive mode)
 <?php (PHP_SAPI != 'cli') and print "SKIP PHP binary is not cli"; ?>
 --FILE--
 <?php
-$fh = popen("{$_ENV['TEST_PHP_EXECUTABLE']} -a", 'w');
+$exe = getenv('TEST_PHP_EXECUTABLE');
+$fh = popen("$exe -a", 'w');
 if ($fh !== false) {
        fwrite($fh, "<?php echo ':test:'; ?>\n\n");
        fclose($fh);