From d68f5509ef7de3e5f0298a47a62e1a2e63082a51 Mon Sep 17 00:00:00 2001 From: Petr Sedlacek Date: Tue, 30 Jan 2018 10:27:38 +0100 Subject: [PATCH] Fix unit test for issue #12648 - incorrect scope of view variables --- tests/unit/Mvc/ViewTest.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/unit/Mvc/ViewTest.php b/tests/unit/Mvc/ViewTest.php index 1044ead3741..6c419893d96 100644 --- a/tests/unit/Mvc/ViewTest.php +++ b/tests/unit/Mvc/ViewTest.php @@ -1022,6 +1022,7 @@ function () { * * @issue 12648 * @author Wojciech Ĺšlawski + * @author Petr Sedlacek * @since 2017-03-17 */ public function testIssue12648() @@ -1040,6 +1041,7 @@ function () { expect($content)->equals("lol

test

\n"); try { echo $a_cool_var; + $this->fail('Variable a_cool_var is defined and is set to "' . $a_cool_var . '"'); } catch (\PHPUnit_Framework_Exception $e) { expect($e->getMessage())->contains("Undefined variable: a_cool_var"); }