summaryrefslogtreecommitdiff
path: root/ext/standard/tests/general_functions/getopt.phpt
blob: e861268459a0a3f815ef92fa6bf7b866382f0a41 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
--TEST--
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');
	}
?>
--FILE--
<?php
	var_dump(getopt("d:m:j:vht"));
?>
--EXPECT--
array(5) {
  ["v"]=>
  bool(false)
  ["h"]=>
  bool(false)
  ["d"]=>
  string(4) "test"
  ["m"]=>
  string(4) "1234"
  ["t"]=>
  bool(false)
}