mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-06 11:24:27 +02:00
added test - bugfix some custom left and right delimiters like '{^' '^}' did not work
https://github.com/smarty-php/smarty/issues/450 https://github.com/smarty-php/smarty/pull/482
This commit is contained in:
@@ -89,4 +89,14 @@ class DelimiterTest extends PHPUnit_Smarty
|
|||||||
$tpl = $this->smarty->createTemplate('eval:{=assign var=foo value="hello world" nocache=}{=$foo=}');
|
$tpl = $this->smarty->createTemplate('eval:{=assign var=foo value="hello world" nocache=}{=$foo=}');
|
||||||
$this->assertEquals("hello world", $this->smarty->fetch($tpl));
|
$this->assertEquals("hello world", $this->smarty->fetch($tpl));
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* test {= =} delimiter for conficts with option flags
|
||||||
|
*/
|
||||||
|
public function testDelimiterIssue450()
|
||||||
|
{
|
||||||
|
$this->smarty->left_delimiter = '{^';
|
||||||
|
$this->smarty->right_delimiter = '^}';
|
||||||
|
$tpl = $this->smarty->createTemplate('eval:{^assign var=foo value="hello world" nocache^}{^$foo^}');
|
||||||
|
$this->assertEquals("hello world", $this->smarty->fetch($tpl));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user