public function LazyOpenStreamTest::testOpensLazily in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/guzzlehttp/psr7/tests/LazyOpenStreamTest.php \GuzzleHttp\Tests\Psr7\LazyOpenStreamTest::testOpensLazily()
File
- vendor/
guzzlehttp/ psr7/ tests/ LazyOpenStreamTest.php, line 26
Class
Namespace
GuzzleHttp\Tests\Psr7Code
public function testOpensLazily() {
$l = new LazyOpenStream($this->fname, 'w+');
$l
->write('foo');
$this
->assertInternalType('array', $l
->getMetadata());
$this
->assertFileExists($this->fname);
$this
->assertEquals('foo', file_get_contents($this->fname));
$this
->assertEquals('foo', (string) $l);
}