1
0
mirror of https://github.com/php/php-src.git synced 2026-04-27 10:16:41 +02:00
Files
archived-php-src/ext/bz2/tests/003.phpt
T
Peter Kokot 6426420f61 Merge branch 'PHP-7.4'
* PHP-7.4:
  Replace dirname(__FILE__) by __DIR__ in tests
2019-03-15 23:36:47 +01:00

34 lines
703 B
PHP

--TEST--
bzread() tests
--SKIPIF--
<?php if (!extension_loaded("bz2")) print "skip"; ?>
--FILE--
<?php
$fd = bzopen(__DIR__."/003.txt.bz2","r");
var_dump(bzread($fd, 0));
var_dump(bzread($fd, -10));
var_dump(bzread($fd, 1));
var_dump(bzread($fd, 2));
var_dump(bzread($fd, 100000));
echo "Done\n";
?>
--EXPECTF--
string(0) ""
Warning: bzread(): length may not be negative in %s on line %d
bool(false)
string(1) "R"
string(2) "is"
string(251) "ing up from the heart of the desert
Rising up for Jerusalem
Rising up from the heat of the desert
Building up Old Jerusalem
Rising up from the heart of the desert
Rising up for Jerusalem
Rising up from the heat of the desert
Heading out for Jerusalem
"
Done