public function load(ImageInterface $image, array $options = array())
{
if (count($options) < 2) {
throw new InvalidArgumentException('Missing width and/or height options');
}
return $this->innerLoader->load($image, array('size' => $options));
}
public function testLoad() { $options = array(123, 456); $image = $this->getMock('\\Imagine\\Image\\ImageInterface'); $this->innerLoader->expects($this->once())->method('load')->with($image, array('size' => $options))->will($this->returnValue($image)); $this->assertSame($image, $this->loader->load($image, $options)); }