public function testCanGetImageContents() { $this->_driverMock->expects($this->once())->method('getBinary')->will($this->returnValue('ImageContents')); $i = new Zend_Image('doesnt-matter.jpg', $this->_driverMock); $this->assertEquals('ImageContents', $i->getBinary()); }