xref: /PHP-8.1/ext/bz2/tests/with_files.phpt (revision 56f90492)
1--TEST--
2BZ2 with files
3--EXTENSIONS--
4bz2
5--FILE--
6<?php
7
8error_reporting(E_ALL);
9
10$filename = "with_files.bz2";
11$str = "This is a test string.\n";
12$bz = bzopen($filename, "w");
13bzwrite($bz, $str);
14bzclose($bz);
15
16$bz = bzopen($filename, "r");
17print bzread($bz, 10);
18print bzread($bz);
19bzclose($bz);
20unlink($filename);
21?>
22--EXPECT--
23This is a test string.
24