Update capture test

This commit is contained in:
uwetews
2016-03-27 18:34:13 +02:00
parent f6a0749845
commit b08b8f1d3a
3 changed files with 10 additions and 0 deletions

View File

@@ -78,6 +78,13 @@ class CompileCaptureTest extends PHPUnit_Smarty
$tpl = $this->smarty->createTemplate('eval:{capture assign=foo}hello {capture assign=bar}this is my {/capture}world{/capture}{$foo} {$bar}');
$this->assertEquals("hello world this is my ", $this->smarty->fetch($tpl), 'This failure pops up only during PHPunit test ?????');
}
/*
* Test that capture results are global
*/
public function testCapture9()
{
$this->assertContains('-->hello world<--', $this->smarty->fetch('009_capture.tpl'));
}
public function testCompileCaptureNocache1()
{

View File

@@ -0,0 +1,2 @@
{capture name='test'}hello world{/capture}
{include '009_capture_include.tpl'}

View File

@@ -0,0 +1 @@
-->{$smarty.capture.test}<--