public function testWriting() { $str = new StringStream('foobar'); $this->assertTrue($str->isWritable()); $str->seek(3); $this->assertEquals(4, $str->write('bazz')); $this->assertEquals('', $str->getContents()); $this->assertEquals('foobazz', $str); $this->assertEquals(7, $str->getSize()); }