--TEST-- stream_set_chunk_size basic tests --FILE-- getMessage() . "\n"; } try { stream_set_chunk_size($f, -1); } catch (ValueError $exception) { echo $exception->getMessage() . "\n"; } ?> --EXPECT-- bool(true) should return previous chunk size (8192) int(8192) should be read without buffer ($count == 10000) read with size: 10000 int(10000) should have no effect on writes write with size: 3 int(3) should return previous chunk size (1) int(1) should elicit one read of size 100 (chunk size) read with size: 100 int(100) should elicit one read of size 100 (chunk size) read with size: 100 int(50) should elicit no read because there is sufficient cached data int(50) should have no effect on writes write with size: 250 int(3) error conditions stream_set_chunk_size(): Argument #2 ($size) must be greater than 0 stream_set_chunk_size(): Argument #2 ($size) must be greater than 0