public function StreamTest::testConstructorInitializesProperties in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/guzzlehttp/psr7/tests/StreamTest.php \GuzzleHttp\Tests\Psr7\StreamTest::testConstructorInitializesProperties()
File
- vendor/
guzzlehttp/ psr7/ tests/ StreamTest.php, line 20
Class
- StreamTest
- @covers GuzzleHttp\Psr7\Stream
Namespace
GuzzleHttp\Tests\Psr7Code
public function testConstructorInitializesProperties() {
$handle = fopen('php://temp', 'r+');
fwrite($handle, 'data');
$stream = new Stream($handle);
$this
->assertTrue($stream
->isReadable());
$this
->assertTrue($stream
->isWritable());
$this
->assertTrue($stream
->isSeekable());
$this
->assertEquals('php://temp', $stream
->getMetadata('uri'));
$this
->assertInternalType('array', $stream
->getMetadata());
$this
->assertEquals(4, $stream
->getSize());
$this
->assertFalse($stream
->eof());
$stream
->close();
}