Annotation of embedaddon/php/ext/bz2/tests/003.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: bzread() tests
3: --SKIPIF--
4: <?php if (!extension_loaded("bz2")) print "skip"; ?>
5: --FILE--
6: <?php
7:
8: $fd = bzopen(dirname(__FILE__)."/003.txt.bz2","r");
9: var_dump(bzread());
10: var_dump(bzread($fd, 1 ,0));
11: var_dump(bzread($fd, 0));
12: var_dump(bzread($fd, -10));
13: var_dump(bzread($fd, 1));
14: var_dump(bzread($fd, 2));
15: var_dump(bzread($fd, 100000));
16:
17: echo "Done\n";
18: ?>
19: --EXPECTF--
20: Warning: bzread() expects at least 1 parameter, 0 given in %s on line %d
21: bool(false)
22:
23: Warning: bzread() expects at most 2 parameters, 3 given in %s on line %d
24: bool(false)
25: string(0) ""
26:
27: Warning: bzread(): length may not be negative in %s on line %d
28: bool(false)
29: string(1) "R"
30: string(2) "is"
31: string(251) "ing up from the heart of the desert
32: Rising up for Jerusalem
33: Rising up from the heat of the desert
34: Building up Old Jerusalem
35: Rising up from the heart of the desert
36: Rising up for Jerusalem
37: Rising up from the heat of the desert
38: Heading out for Jerusalem
39: "
40: Done
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>