public function StreamTest::testGetsContents in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/guzzlehttp/psr7/tests/StreamTest.php \GuzzleHttp\Tests\Psr7\StreamTest::testGetsContents()
File
- vendor/
guzzlehttp/ psr7/ tests/ StreamTest.php, line 53
Class
- StreamTest
- @covers GuzzleHttp\Psr7\Stream
Namespace
GuzzleHttp\Tests\Psr7Code
public function testGetsContents() {
$handle = fopen('php://temp', 'w+');
fwrite($handle, 'data');
$stream = new Stream($handle);
$this
->assertEquals('', $stream
->getContents());
$stream
->seek(0);
$this
->assertEquals('data', $stream
->getContents());
$this
->assertEquals('', $stream
->getContents());
}