1--TEST--
2Test function posix_seteuid() by substituting argument 1 with string values.
3--SKIPIF--
4<?php
5        if(!extension_loaded("posix")) print "skip - POSIX extension not loaded";
6?>
7--CREDITS--
8Marco Fabbri mrfabbri@gmail.com
9Francesco Fullone ff@ideato.it
10#PHPTestFest Cesena Italia on 2009-06-20
11--FILE--
12<?php
13
14
15echo "*** Test substituting argument 1 with string values ***\n";
16
17
18
19$heredoc = <<<EOT
20hello world
21EOT;
22
23$variation_array = array(
24  'string DQ' => "string",
25  'string SQ' => 'string',
26  'mixed case string' => "sTrInG",
27  'heredoc' => $heredoc,
28  );
29
30
31foreach ( $variation_array as $var ) {
32  var_dump(posix_seteuid( $var  ) );
33}
34?>
35--EXPECTF--
36*** Test substituting argument 1 with string values ***
37
38Warning: posix_seteuid() expects parameter 1 to be int, string given in %s on line 21
39bool(false)
40
41Warning: posix_seteuid() expects parameter 1 to be int, string given in %s on line 21
42bool(false)
43
44Warning: posix_seteuid() expects parameter 1 to be int, string given in %s on line 21
45bool(false)
46
47Warning: posix_seteuid() expects parameter 1 to be int, string given in %s on line 21
48bool(false)
49