fix test that that would not fail if no exception is thrown
authorTobias Schultze <webmaster@tubo-world.de>
Sun, 9 Dec 2012 16:21:53 +0000 (17:21 +0100)
committerTobias Schultze <webmaster@tubo-world.de>
Fri, 15 Mar 2013 11:00:24 +0000 (12:00 +0100)
test/Twig/Tests/TemplateTest.php

index 050c37f..26685a6 100644 (file)
@@ -34,8 +34,9 @@ class Twig_Tests_TemplateTest extends PHPUnit_Framework_TestCase
 
         try {
             $template->render($context);
+            $this->fail('Accessing an invalid item should throw an exception.');
         } catch (Twig_Error_Runtime $e) {
-            $this->assertEquals(sprintf($message, $name), $e->getMessage());
+            $this->assertSame(sprintf($message, $name), $e->getMessage());
         }
     }