Author: Christer Edvartsen (cogo@starzinger.net)
Inheritance: extends Transformation, implements Imbo\EventListener\ListenerInterface
Example #1
0
 /**
  * @expectedException Imbo\Exception\TransformationException
  * @expectedExceptionMessage error
  * @expectedExceptionCode 400
  */
 public function testThrowsCorrectExceptionWhenAnErrorOccurs()
 {
     $imagickException = new ImagickException('error');
     $imagick = $this->getMock('Imagick');
     $imagick->expects($this->once())->method('stripImage')->will($this->throwException($imagickException));
     $transformation = new Strip();
     $transformation->setImagick($imagick)->transform($this->getMock('Imbo\\EventManager\\Event'));
 }