Skip to content

Commit

Permalink
even more verbose assertRenders
Browse files Browse the repository at this point in the history
  • Loading branch information
woru committed Sep 26, 2013
1 parent dc13d73 commit e2aae7c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/Ouzo/Tests/ControllerTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,9 @@ private function _removePrefix($string)
public function assertRenders($string)
{
$statusResponse = $this->_frontController->getCurrentController()->getStatusResponse();
$location = $this->_frontController->getCurrentController()->getRedirectLocation();
if ($statusResponse != 'show') {
$this->fail("Expected render but was $statusResponse");
$this->fail("Expected render $string but was $statusResponse $location");
}
$this->assertEquals($string, $this->_frontController->getCurrentController()->view->getViewName());
}
Expand Down

0 comments on commit e2aae7c

Please sign in to comment.