getImage() публичный Метод

Fetch an image via a short URL
public getImage ( Imbo\EventManager\EventInterface $event )
$event Imbo\EventManager\EventInterface
Пример #1
0
 /**
  * @covers Imbo\Resource\GlobalShortUrl::getImage
  * @expectedException Imbo\Exception\ResourceException
  * @expectedExceptionMessage Image not found
  * @expectedExceptionCode 404
  */
 public function testRespondsWith404WhenShortUrlDoesNotExist()
 {
     $route = $this->getMock('Imbo\\Router\\Route');
     $route->expects($this->once())->method('get')->with('shortUrlId')->will($this->returnValue('aaaaaaa'));
     $this->request->expects($this->once())->method('getRoute')->will($this->returnValue($route));
     $this->database->expects($this->once())->method('getShortUrlParams')->with('aaaaaaa')->will($this->returnValue(null));
     $this->resource->getImage($this->event);
 }