Annotation of embedaddon/php/ext/posix/tests/posix_ttyname_variation7.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Test function posix_ttyname() by substituting argument 1 with string values.
3: --CREDITS--
4: Marco Fabbri mrfabbri@gmail.com
5: Francesco Fullone ff@ideato.it
6: #PHPTestFest Cesena Italia on 2009-06-20
7: --SKIPIF--
8: <?php
9: if (!extension_loaded('posix')) {
10: die('SKIP The posix extension is not loaded.');
11: }
12: ?>
13: --FILE--
14: <?php
15:
16:
17: echo "*** Test substituting argument 1 with string values ***\n";
18:
19:
20:
21: $heredoc = <<<EOT
22: hello world
23: EOT;
24:
25: $variation_array = array(
26: 'string DQ' => "string",
27: 'string SQ' => 'string',
28: 'mixed case string' => "sTrInG",
29: 'heredoc' => $heredoc,
30: );
31:
32:
33: foreach ( $variation_array as $var ) {
34: var_dump(posix_ttyname( $var ) );
35: }
36: ?>
37: --EXPECTF--
38: *** Test substituting argument 1 with string values ***
39: bool(false)
40: bool(false)
41: bool(false)
42: bool(false)
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>