public function BufferStreamTest::testRemovesReadDataFromBuffer in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/guzzlehttp/psr7/tests/BufferStreamTest.php \GuzzleHttp\Tests\Psr7\BufferStreamTest::testRemovesReadDataFromBuffer()
File
- vendor/
guzzlehttp/ psr7/ tests/ BufferStreamTest.php, line 19
Class
Namespace
GuzzleHttp\Tests\Psr7Code
public function testRemovesReadDataFromBuffer() {
$b = new BufferStream();
$this
->assertEquals(3, $b
->write('foo'));
$this
->assertEquals(3, $b
->getSize());
$this
->assertFalse($b
->eof());
$this
->assertEquals('foo', $b
->read(10));
$this
->assertTrue($b
->eof());
$this
->assertEquals('', $b
->read(10));
}