Files
smarty/tests/UnitTests/TemplateSource/_Issues/422/NestedLoopIssue422Test.php
2022-09-27 12:03:34 +02:00

36 lines
678 B
PHP

<?php
/**
* Smarty PHPunit tests compiler errors
*
* @package PHPunit
* @author Uwe Tews
*/
/**
* class for compiler tests
*
* @runTestsInSeparateProcess
* @preserveGlobalState disabled
* @backupStaticAttributes enabled
*
* Problem with total property of {section} and {foreach} in nested loop
*/
class NestedLoopIssue422Test extends PHPUnit_Smarty
{
public function setUp(): void
{
$this->setUpSmarty(__DIR__);
}
public function testInit()
{
$this->cleanDirs();
}
public function testnested422()
{
$this->assertEquals('loop: 1inner: 0loop: 2inner: 1', $this->smarty->fetch('422_test.tpl'));
}
}