test: add test simulating reading 0 bytes from the stream