xref: /PHP-5.4/sapi/cli/tests/012.phpt (revision 829d08e5)
1--TEST--
2invalid arguments and error messages
3--SKIPIF--
4<?php include "skipif.inc"; ?>
5--FILE--
6<?php
7
8$php = getenv('TEST_PHP_EXECUTABLE');
9
10var_dump(`"$php" -n -F some.php -F some.php`);
11var_dump(`"$php" -n -F some.php -R some.php`);
12var_dump(`"$php" -n -R some.php -F some.php`);
13var_dump(`"$php" -n -R some.php -R some.php`);
14var_dump(`"$php" -n -f some.php -f some.php`);
15var_dump(`"$php" -n -B '' -B ''`);
16var_dump(`"$php" -n -E '' -E ''`);
17var_dump(`"$php" -n -r '' -r ''`);
18
19echo "Done\n";
20?>
21--EXPECTF--
22string(32) "You can use -R or -F only once.
23"
24string(32) "You can use -R or -F only once.
25"
26string(32) "You can use -R or -F only once.
27"
28string(32) "You can use -R or -F only once.
29"
30string(26) "You can use -f only once.
31"
32string(26) "You can use -B only once.
33"
34string(26) "You can use -E only once.
35"
36string(26) "You can use -r only once.
37"
38Done
39