Annotation of embedaddon/php/ext/zlib/tests/004.phpt, revision 1.1.1.2
1.1 misho 1: --TEST--
2: gzfile() with various invalid params
3: --SKIPIF--
4: <?php if (!extension_loaded("zlib")) print "skip"; ?>
5: --FILE--
6: <?php
7:
8: var_dump(gzfile());
9: var_dump(gzfile("nonexistent_file_gzfile",1));
10: var_dump(gzfile(1,1,1));
11:
12: var_dump(gzfile(dirname(__FILE__)."/004.txt.gz"));
13: var_dump(gzfile(dirname(__FILE__)."/004.txt.gz", 1));
14:
15: echo "Done\n";
16: ?>
17: --EXPECTF--
18: Warning: gzfile() expects at least 1 parameter, 0 given in %s on line %d
19: NULL
20:
21: Warning: gzfile(nonexistent_file_gzfile): failed to open stream: No such file or directory in %s on line %d
22: bool(false)
23:
24: Warning: gzfile() expects at most 2 parameters, 3 given in %s on line %d
25: NULL
26: array(6) {
27: [0]=>
28: string(36) "When you're taught through feelings
29: "
30: [1]=>
31: string(26) "Destiny flying high above
32: "
33: [2]=>
34: string(38) "all I know is that you can realize it
35: "
36: [3]=>
37: string(18) "Destiny who cares
38: "
39: [4]=>
40: string(19) "as it turns around
41: "
42: [5]=>
43: string(39) "and I know that it descends down on me
44: "
45: }
46: array(6) {
47: [0]=>
48: string(36) "When you're taught through feelings
49: "
50: [1]=>
51: string(26) "Destiny flying high above
52: "
53: [2]=>
54: string(38) "all I know is that you can realize it
55: "
56: [3]=>
57: string(18) "Destiny who cares
58: "
59: [4]=>
60: string(19) "as it turns around
61: "
62: [5]=>
63: string(39) "and I know that it descends down on me
64: "
65: }
66: Done
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>