mirror of
https://github.com/smarty-php/smarty.git
synced 2025-11-03 05:41:37 +01:00
* Removed unneeded files and replace dummy.txt with .gitignore files * Synced unit tests with master codebase, noted TODO's, fixed phpunit scripts and travis config * fix php7.4 deprecation and remove php7.4 from travis allow_failures since php7.4 is current stable Co-authored-by: Uwe Tews <uwe.tews@googlemail.com> Co-authored-by: Uwe Tews <uwe.tews@gmail.com> Co-authored-by: AnrDaemon <anrdaemon@yandex.ru>
36 lines
682 B
PHP
36 lines
682 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()
|
|
{
|
|
$this->setUpSmarty(dirname(__FILE__));
|
|
}
|
|
|
|
public function testInit()
|
|
{
|
|
$this->cleanDirs();
|
|
}
|
|
|
|
public function testnested422()
|
|
{
|
|
$this->assertEquals('loop: 1inner: 0loop: 2inner: 1', $this->smarty->fetch('422_test.tpl'));
|
|
}
|
|
|
|
}
|