Skip to content

Commit

Permalink
Fix parser test to reflect that in if/elseif constructs a dollar sign…
Browse files Browse the repository at this point in the history
… is no long automatically inserted to allow for more flexible if statements.
  • Loading branch information
lonnieezell committed Aug 19, 2018
1 parent 22416e5 commit c1bc16b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/system/View/ParserTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -456,7 +456,7 @@ public function testIfConditionalTrue()
'dontdoit' => false
];

$template = "{if doit}Howdy{endif}{ if dontdoit === false}Welcome{ endif }";
$template = "{if \$doit}Howdy{endif}{ if \$dontdoit === false}Welcome{ endif }";
$parser->setData($data);

$this->assertEquals('HowdyWelcome', $parser->renderString($template));
Expand All @@ -469,7 +469,7 @@ public function testElseConditionalFalse()
'doit' => true,
];

$template = "{if doit}Howdy{else}Welcome{ endif }";
$template = "{if \$doit}Howdy{else}Welcome{ endif }";
$parser->setData($data);

$this->assertEquals('Howdy', $parser->renderString($template));
Expand All @@ -482,7 +482,7 @@ public function testElseConditionalTrue()
'doit' => false,
];

$template = "{if doit}Howdy{else}Welcome{ endif }";
$template = "{if \$doit}Howdy{else}Welcome{ endif }";
$parser->setData($data);

$this->assertEquals('Welcome', $parser->renderString($template));
Expand All @@ -496,7 +496,7 @@ public function testElseifConditionalTrue()
'dontdoit' => true
];

$template = "{if doit}Howdy{elseif dontdoit}Welcome{ endif }";
$template = "{if \$doit}Howdy{elseif \$dontdoit}Welcome{ endif }";
$parser->setData($data);

$this->assertEquals('Welcome', $parser->renderString($template));
Expand Down

0 comments on commit c1bc16b

Please sign in to comment.