From 609ae0d708cd0b022535d97625e7c5a3c34c7ba4 Mon Sep 17 00:00:00 2001 From: Uwe Tews Date: Sun, 14 Jun 2015 02:56:18 +0200 Subject: [PATCH] Update for 3.1.25 --- tests/PHPUnit_Smarty.php | 31 ++--- .../ModifiedSince/HttpModifiedSinceTest.php | 1 + .../ResourceTests/File/FileResourceTest.php | 21 +++- .../File/IndexedFileResourceTest.php | 21 ++-- .../ResourceTests/Php/PhpResourceTest.php | 2 +- .../BockExtend/CompileBlockExtendsTest.php | 3 - ...e.test_template_function_003.tpl.cache.php | 98 --------------- ...e.test_template_function_002.tpl.cache.php | 99 --------------- ...1a_0.file.test_define_function_tag.tpl.php | 67 ----------- ..._0.file.test_template_function_003.tpl.php | 98 --------------- ...0.file.test_template_function_tag2.tpl.php | 69 ----------- ...e.test_template_function_002.tpl.cache.php | 97 --------------- ...0.file.test_template_function_tag5.tpl.php | 68 ----------- ...1.file.test_template_function_tag5.tpl.php | 87 -------------- ...0.file.test_template_function_tag6.tpl.php | 32 ----- ...1.file.test_template_function_tag6.tpl.php | 104 ---------------- ...mplate_function_nocache_call.tpl.cache.php | 32 ----- ...mplate_function_nocache_call.tpl.cache.php | 113 ------------------ ....file.test_template_function.tpl.cache.php | 31 ----- ....file.test_template_function.tpl.cache.php | 112 ----------------- ..._0.file.test_inherit_function_tag6.tpl.php | 30 ----- ...a_0.file.test_inherit_function_tag.tpl.php | 30 ----- ...e.test_template_function_001.tpl.cache.php | 68 ----------- ..._0.file.test_template_function_001.tpl.php | 68 ----------- ...0.file.template_function_lib.tpl.cache.php | 95 --------------- ...0.file.test_template_function_tag4.tpl.php | 67 ----------- 26 files changed, 44 insertions(+), 1500 deletions(-) delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/2e9582e4d4f31291755140d7b123bc17fbaa811a_0.file.test_define_function_tag.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6cb7077cbab7f8057647b7b11f55f38f2da9dc36_0.file.test_template_function_tag2.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_0.file.test_template_function_tag5.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_1.file.test_template_function_tag5.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_0.file.test_template_function_tag6.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_1.file.test_template_function_tag6.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_0.file.test_template_function_nocache_call.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_1.file.test_template_function_nocache_call.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_0.file.test_template_function.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_1.file.test_template_function.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/c43995ee759c6c7f171e915aace16ee91ee059a9_0.file.test_inherit_function_tag6.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d0ce3d3da7d8c86b14875fc36c9fccde5dc190ba_0.file.test_inherit_function_tag.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/dfb143ec1fbcb556e13ac1f174c3b8394191bd18_0.file.template_function_lib.tpl.cache.php delete mode 100644 tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/f07aa3eeb4dea4c19bbd2f4c2ae3f28f1776589c_0.file.test_template_function_tag4.tpl.php diff --git a/tests/PHPUnit_Smarty.php b/tests/PHPUnit_Smarty.php index 53d5cea4..f2539862 100644 --- a/tests/PHPUnit_Smarty.php +++ b/tests/PHPUnit_Smarty.php @@ -74,6 +74,10 @@ class PHPUnit_Smarty extends PHPUnit_Framework_TestCase 'PHPUnit_Smarty' => array('config', 'pdo', 'init'), ); + private $dsMap = array('/' => array(array('\\', '/./'), '/.'), + '\\' => array(array('/', '\\.\\'), '\\.'), + ); + /** * This method is called before the first test of this test class is run. * @@ -311,8 +315,7 @@ KEY `expire` (`expire`) case 'file': case 'filetest': case 'php': - return $dir . $name; - return $this->normalizePath($dir . $name); + return $this->normalizePath($dir . $name); case 'mysqltest': case 'mysql': return sha1($type . ':' . $name); @@ -343,9 +346,9 @@ KEY `expire` (`expire`) case 'file': case 'filetest': if ($tpl instanceof Smarty) { - return sha1(getcwd() . $this->normalizePath($this->smarty->getTemplateDir(0) . $name)); + return sha1($this->normalizePath($this->smarty->getTemplateDir(0) . $name)); } - return sha1(getcwd() . $tpl->source->filepath); + return sha1($tpl->source->filepath); case 'mysqltest': case 'mysql': return sha1($type . ':' . $name); @@ -357,21 +360,21 @@ KEY `expire` (`expire`) } /** - * Normalize file path + * Normalize path + * - remove /./ and /../ + * - make it absolute * - * @param string $path input path - * @param bool $ds if true use system directory separator + * @param string $path file path * * @return string */ - public function normalizePath($path, $ds = false) - { - $path = str_replace(array('\\', '/./'), '/', $path); - while ($path !== $new = preg_replace('#[^\.\/]+/\.\./#', '', $path)) { - $path = $new; + public function normalizePath($path) { + if ($path[0] == '.') { + $path = getcwd() . DS . $path; } - if (DS !== '/' && $ds) { - $path = str_replace('/', DS, $path); + $path = str_replace($this->dsMap[DS][0], DS, $path); + while (strrpos($path, $this->dsMap[DS][1]) !== false) { + $path = preg_replace('#([\\\/][.][\\\/])|([\\\/][^\\\/]+[\\\/][.][.][\\\/])#', DS, $path); } return $path; } diff --git a/tests/UnitTests/CacheModify/ModifiedSince/HttpModifiedSinceTest.php b/tests/UnitTests/CacheModify/ModifiedSince/HttpModifiedSinceTest.php index 99f0495f..aeee8fac 100644 --- a/tests/UnitTests/CacheModify/ModifiedSince/HttpModifiedSinceTest.php +++ b/tests/UnitTests/CacheModify/ModifiedSince/HttpModifiedSinceTest.php @@ -123,6 +123,7 @@ class HttpModifiedSinceTest extends PHPUnit_Smarty public function testEnabledCached3() { + //$_SERVER['SERVER_PROTOCOL'] = 'HTTP/1.1'; $_SERVER['SMARTY_PHPUNIT_HEADERS'] = array(); $_SERVER['HTTP_IF_MODIFIED_SINCE'] = gmdate('D, d M Y H:i:s', time() + 10) . ' GMT'; $this->smarty->setCacheModifiedCheck(true); diff --git a/tests/UnitTests/ResourceTests/File/FileResourceTest.php b/tests/UnitTests/ResourceTests/File/FileResourceTest.php index 49123fd1..0cbec86a 100644 --- a/tests/UnitTests/ResourceTests/File/FileResourceTest.php +++ b/tests/UnitTests/ResourceTests/File/FileResourceTest.php @@ -36,7 +36,7 @@ class FileResourceTest extends PHPUnit_Smarty public function testGetTemplateFilepath() { $tpl = $this->smarty->createTemplate('helloworld.tpl'); - $this->assertEquals("./templates/helloworld.tpl", str_replace('\\', '/', $tpl->source->filepath)); + $this->assertEquals($this->normalizePath("./templates/helloworld.tpl"), $tpl->source->filepath); } public function testTemplateFileExists1() @@ -407,10 +407,10 @@ class FileResourceTest extends PHPUnit_Smarty $this->smarty->setCompileDir($dn . '/templates_c/'); $this->smarty->setCacheDir($dn . '/cache/'); + chdir($dn . '/templates/relativity/theory/'); $this->smarty->setTemplateDir(array( $dn . '/templates/', )); - chdir($dn . '/templates/relativity/theory/'); $map = array( 'foo.tpl' => 'theory', @@ -451,6 +451,9 @@ class FileResourceTest extends PHPUnit_Smarty ); chdir($dn . '/templates/relativity/theory/'); + $this->smarty->setTemplateDir(array( + $dn . '/templates/relativity/theory/einstein/', + )); $this->_relativeMap($map, $cwd); $map = array( @@ -464,6 +467,9 @@ class FileResourceTest extends PHPUnit_Smarty ); chdir($dn . '/templates/relativity/theory/'); + $this->smarty->setTemplateDir(array( + $dn . '/templates/relativity/theory/einstein/', + )); $this->_relativeMap($map, $cwd); } @@ -487,6 +493,9 @@ class FileResourceTest extends PHPUnit_Smarty ); chdir($dn . '/templates/relativity/theory/einstein'); + $this->smarty->setTemplateDir(array( + '../..', + )); $this->_relativeMap($map, $cwd); $map = array( @@ -497,6 +506,9 @@ class FileResourceTest extends PHPUnit_Smarty ); chdir($dn . '/templates/relativity/theory/einstein/'); + $this->smarty->setTemplateDir(array( + '../..', + )); $this->_relativeMap($map, $cwd); $map = array( @@ -512,10 +524,10 @@ class FileResourceTest extends PHPUnit_Smarty '.././relativity.tpl' => 'relativity', ); + chdir($dn . '/templates/relativity/theory/einstein/'); $this->smarty->setTemplateDir(array( '..', )); - chdir($dn . '/templates/relativity/theory/einstein/'); $this->_relativeMap($map, $cwd); } @@ -545,6 +557,9 @@ class FileResourceTest extends PHPUnit_Smarty ); chdir($dn . '/templates/relativity/theory/einstein/'); + $this->smarty->setTemplateDir(array( + '..', + )); $this->_relativeMap($map, $cwd); } } diff --git a/tests/UnitTests/ResourceTests/File/IndexedFileResourceTest.php b/tests/UnitTests/ResourceTests/File/IndexedFileResourceTest.php index bc9970da..7a4460de 100644 --- a/tests/UnitTests/ResourceTests/File/IndexedFileResourceTest.php +++ b/tests/UnitTests/ResourceTests/File/IndexedFileResourceTest.php @@ -12,42 +12,35 @@ class IndexedFileResourceTest extends PHPUnit_Smarty public function setUp() { $this->setUpSmarty(__DIR__); - $path = str_replace(array("\\", "/"), DS, dirname(__FILE__)); - $this->smarty->addTemplateDir($path . DS. 'templates_2'); + $this->smarty->addTemplateDir(__DIR__ . '/templates_2'); // note that 10 is a string! - $this->smarty->addTemplateDir($path . DS. 'templates_3', '10'); - $this->smarty->addTemplateDir($path . DS . 'templates_4', 'foo'); + $this->smarty->addTemplateDir(__DIR__ . '/templates_3', '10'); + $this->smarty->addTemplateDir(__DIR__ . '/templates_4', 'foo'); } - protected function relative($path) - { - $path = str_replace(str_replace("\\", "/", dirname(__FILE__)), '.', str_replace("\\", "/", $path)); - - return $path; - } public function testGetTemplateFilepath() { $tpl = $this->smarty->createTemplate('dirname.tpl'); - $this->assertEquals("./templates/dirname.tpl", $this->relative($tpl->source->filepath)); + $this->assertEquals($this->normalizePath("./templates/dirname.tpl"), $tpl->source->filepath); } public function testGetTemplateFilepathNumber() { $tpl = $this->smarty->createTemplate('[1]dirname.tpl'); - $this->assertEquals('./templates_2/dirname.tpl', $this->relative($tpl->source->filepath)); + $this->assertEquals($this->normalizePath('./templates_2/dirname.tpl'), $tpl->source->filepath); } public function testGetTemplateFilepathNumeric() { $tpl = $this->smarty->createTemplate('[10]dirname.tpl'); - $this->assertEquals('./templates_3/dirname.tpl', $this->relative($tpl->source->filepath)); + $this->assertEquals($this->normalizePath('./templates_3/dirname.tpl'), $tpl->source->filepath); } public function testGetTemplateFilepathName() { $tpl = $this->smarty->createTemplate('[foo]dirname.tpl'); - $this->assertEquals('./templates_4/dirname.tpl', $this->relative($tpl->source->filepath)); + $this->assertEquals($this->normalizePath('./templates_4/dirname.tpl'), $tpl->source->filepath); } public function testFetch() diff --git a/tests/UnitTests/ResourceTests/Php/PhpResourceTest.php b/tests/UnitTests/ResourceTests/Php/PhpResourceTest.php index d8f6a4db..b2888a82 100644 --- a/tests/UnitTests/ResourceTests/Php/PhpResourceTest.php +++ b/tests/UnitTests/ResourceTests/Php/PhpResourceTest.php @@ -36,7 +36,7 @@ class PhpResourceTest extends PHPUnit_Smarty public function testGetTemplateFilepath() { $tpl = $this->smarty->createTemplate('php:phphelloworld.php'); - $this->assertEquals("./templates/phphelloworld.php", str_replace('\\', '/', $tpl->source->filepath)); + $this->assertEquals($this->normalizePath("./templates/phphelloworld.php"), $tpl->source->filepath); } /** diff --git a/tests/UnitTests/TemplateSource/TagTests/BockExtend/CompileBlockExtendsTest.php b/tests/UnitTests/TemplateSource/TagTests/BockExtend/CompileBlockExtendsTest.php index 5b1e215e..61f921ed 100644 --- a/tests/UnitTests/TemplateSource/TagTests/BockExtend/CompileBlockExtendsTest.php +++ b/tests/UnitTests/TemplateSource/TagTests/BockExtend/CompileBlockExtendsTest.php @@ -332,7 +332,6 @@ class CompileBlockExtendsTest extends PHPUnit_Smarty /** * @expectedException SmartyCompilerException - * @expectedExceptionMessage Syntax error in template "./templates/025_parent.tpl" * @expectedExceptionMessage tag {$smarty.block.child} used outside {block} tags * test {$this->smarty.block.child} outside {block] */ @@ -343,7 +342,6 @@ class CompileBlockExtendsTest extends PHPUnit_Smarty /** * @expectedException SmartyCompilerException - * @expectedExceptionMessage Syntax error in template "./templates/026_parent.tpl" * @expectedExceptionMessage tag {$smarty.block.parent} used outside {block} tags * test {$this->smarty.block.parent} outside {block] */ @@ -354,7 +352,6 @@ class CompileBlockExtendsTest extends PHPUnit_Smarty /** * @expectedException SmartyCompilerException - * @expectedExceptionMessage Syntax error in template "./templates/027_parent.tpl" * @expectedExceptionMessage illegal {$smarty.block.parent} in parent template * test {$this->smarty.block.parent} in parent template */ diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.cache.php deleted file mode 100644 index efb48f9b..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.cache.php +++ /dev/null @@ -1,98 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '422f9371d4d2d9de15c6d6b506a1de7f4d71063d' => - array ( - 0 => './templates/test_template_function_003.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '12318554f33a0dd75e8_81553017', - 'variables' => - array ( - 'default' => 1, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a0df8d73_61285923', - 'tpl_function' => - array ( - 'functest' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/1^422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.cache.php', - 'uid' => '422f9371d4d2d9de15c6d6b506a1de7f4d71063d', - 'call_name_caching' => 'smarty_template_function_functest_12318554f33a0dd75e8_81553017_nocache', - 'call_name' => 'smarty_template_function_functest_12318554f33a0dd75e8_81553017', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a0df8d73_61285923')) { -function content_554f33a0df8d73_61285923 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '12318554f33a0dd75e8_81553017'; -$_smarty_tpl->callTemplateFunction ('functest', $_smarty_tpl, array(), false);?> -/*/%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/'; -ob_start(); -$params = array_merge(array('default'=>'default'), $params); -$_smarty_tpl->properties['saved_tpl_vars'][] = $_smarty_tpl->tpl_vars; -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -}$params = var_export($params, true); -echo "/*%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/tpl_vars; -foreach ($params as \$key => \$value) { -\$_smarty_tpl->tpl_vars[\$key] = new Smarty_Variable(\$value); -} -?>/*/%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/ -"; -echo '/*%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/tpl_vars[\'default\']->value;?> -/*/%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/';?> - 1),$_smarty_tpl);?> -/*/%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/'; -echo "/*%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/ \$value){ -if (\$_smarty_tpl->tpl_vars[\$key] === \$value) \$saved_tpl_vars[\$key] = \$value; -} -\$_smarty_tpl->tpl_vars = \$saved_tpl_vars;?> -/*/%%SmartyNocache:12318554f33a0dd75e8_81553017%%*/"; -?>properties['nocache_hash'], ob_get_clean()); -$_smarty_tpl->tpl_vars = array_pop($_smarty_tpl->properties['saved_tpl_vars']); -} -} -/*/ smarty_template_function_functest_12318554f33a0dd75e8_81553017_nocache */ -/* smarty_template_function_functest_12318554f33a0dd75e8_81553017 */ -if (!function_exists('smarty_template_function_functest_12318554f33a0dd75e8_81553017')) { -function smarty_template_function_functest_12318554f33a0dd75e8_81553017($_smarty_tpl,$params) { -if (!is_callable('smarty_function_counter')) require_once 'C:/wamp/www/Smarty3.1-test-release/vendor/smarty/smarty/libs/plugins/function.counter.php'; -$saved_tpl_vars = $_smarty_tpl->tpl_vars; -$params = array_merge(array('default'=>'default'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['default']->value;?> - 1),$_smarty_tpl); -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest_12318554f33a0dd75e8_81553017 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php deleted file mode 100644 index 59824358..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/1^6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php +++ /dev/null @@ -1,99 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '6df2384df0a3755f460437207bf362b39a168f74' => - array ( - 0 => './templates/test_template_function_002.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '22688554f33a06da492_37365358', - 'variables' => - array ( - 'default' => 1, - 'param' => 0, - ), - 'has_nocache_code' => true, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a0711af3_13839557', - 'tpl_function' => - array ( - 'functest' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/1^6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php', - 'uid' => '6df2384df0a3755f460437207bf362b39a168f74', - 'call_name_caching' => 'smarty_template_function_functest_22688554f33a06da492_37365358_nocache', - 'call_name' => 'smarty_template_function_functest_22688554f33a06da492_37365358', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a0711af3_13839557')) { -function content_554f33a0711af3_13839557 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '22688554f33a06da492_37365358'; -$_smarty_tpl->callTemplateFunction ('functest', $_smarty_tpl, array('param'=>'param'), false);?> - callTemplateFunction ('functest', $_smarty_tpl, array('param'=>$_smarty_tpl->tpl_vars['param']->value), false);?> - callTemplateFunction (\'functest\', $_smarty_tpl, array(\'param\'=>$_smarty_tpl->tpl_vars[\'param\']->value,\'default\'=>$_smarty_tpl->tpl_vars[\'default\']->value), true);?> -/*/%%SmartyNocache:22688554f33a06da492_37365358%%*/';?> -'default'), $params); -$_smarty_tpl->properties['saved_tpl_vars'][] = $_smarty_tpl->tpl_vars; -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -}$params = var_export($params, true); -echo "/*%%SmartyNocache:22688554f33a06da492_37365358%%*/tpl_vars; -foreach ($params as \$key => \$value) { -\$_smarty_tpl->tpl_vars[\$key] = new Smarty_Variable(\$value); -} -?>/*/%%SmartyNocache:22688554f33a06da492_37365358%%*/ -"; -echo '/*%%SmartyNocache:22688554f33a06da492_37365358%%*/tpl_vars[\'default\']->value;?> -/*/%%SmartyNocache:22688554f33a06da492_37365358%%*/';?> - tpl_vars[\'param\']->value;?> -/*/%%SmartyNocache:22688554f33a06da492_37365358%%*/'; -echo "/*%%SmartyNocache:22688554f33a06da492_37365358%%*/ \$value){ -if (\$_smarty_tpl->tpl_vars[\$key] === \$value) \$saved_tpl_vars[\$key] = \$value; -} -\$_smarty_tpl->tpl_vars = \$saved_tpl_vars;?> -/*/%%SmartyNocache:22688554f33a06da492_37365358%%*/"; -?>properties['nocache_hash'], ob_get_clean()); -$_smarty_tpl->tpl_vars = array_pop($_smarty_tpl->properties['saved_tpl_vars']); -} -} -/*/ smarty_template_function_functest_22688554f33a06da492_37365358_nocache */ -/* smarty_template_function_functest_22688554f33a06da492_37365358 */ -if (!function_exists('smarty_template_function_functest_22688554f33a06da492_37365358')) { -function smarty_template_function_functest_22688554f33a06da492_37365358($_smarty_tpl,$params) { -$saved_tpl_vars = $_smarty_tpl->tpl_vars; -$params = array_merge(array('default'=>'default'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['default']->value;?> - tpl_vars['param']->value; -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest_22688554f33a06da492_37365358 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/2e9582e4d4f31291755140d7b123bc17fbaa811a_0.file.test_define_function_tag.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/2e9582e4d4f31291755140d7b123bc17fbaa811a_0.file.test_define_function_tag.tpl.php deleted file mode 100644 index 4269c097..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/2e9582e4d4f31291755140d7b123bc17fbaa811a_0.file.test_define_function_tag.tpl.php +++ /dev/null @@ -1,67 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '2e9582e4d4f31291755140d7b123bc17fbaa811a' => - array ( - 0 => './templates/test_define_function_tag.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '24823554f33a1d764f9_03909341', - 'variables' => - array ( - 'loop' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a1d9b877_15698903', - 'tpl_function' => - array ( - 'functest6i' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/2e9582e4d4f31291755140d7b123bc17fbaa811a_0.file.test_define_function_tag.tpl.php', - 'uid' => '2e9582e4d4f31291755140d7b123bc17fbaa811a', - 'call_name' => 'smarty_template_function_functest6i_24823554f33a1d764f9_03909341', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a1d9b877_15698903')) { -function content_554f33a1d9b877_15698903 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '24823554f33a1d764f9_03909341'; -?> -tpl_vars; -$params = array_merge(array('loop'=>0), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['loop']->value; -if ($_smarty_tpl->tpl_vars['loop']->value<5) { -$_smarty_tpl->callTemplateFunction ('functest6i', $_smarty_tpl, array('loop'=>$_smarty_tpl->tpl_vars['loop']->value+1), false); -} -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest6i_24823554f33a1d764f9_03909341 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.php deleted file mode 100644 index e01136f8..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.php +++ /dev/null @@ -1,98 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '422f9371d4d2d9de15c6d6b506a1de7f4d71063d' => - array ( - 0 => './templates/test_template_function_003.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '11353554f33a0b12c39_38927265', - 'variables' => - array ( - 'default' => 1, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a0b34e64_35437774', - 'tpl_function' => - array ( - 'functest' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/422f9371d4d2d9de15c6d6b506a1de7f4d71063d_0.file.test_template_function_003.tpl.php', - 'uid' => '422f9371d4d2d9de15c6d6b506a1de7f4d71063d', - 'call_name_caching' => 'smarty_template_function_functest_11353554f33a0b12c39_38927265_nocache', - 'call_name' => 'smarty_template_function_functest_11353554f33a0b12c39_38927265', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a0b34e64_35437774')) { -function content_554f33a0b34e64_35437774 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '11353554f33a0b12c39_38927265'; -$_smarty_tpl->callTemplateFunction ('functest', $_smarty_tpl, array(), true);?> -/*/%%SmartyNocache:11353554f33a0b12c39_38927265%%*/'; -ob_start(); -$params = array_merge(array('default'=>'default'), $params); -$_smarty_tpl->properties['saved_tpl_vars'][] = $_smarty_tpl->tpl_vars; -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -}$params = var_export($params, true); -echo "/*%%SmartyNocache:11353554f33a0b12c39_38927265%%*/tpl_vars; -foreach ($params as \$key => \$value) { -\$_smarty_tpl->tpl_vars[\$key] = new Smarty_Variable(\$value); -} -?>/*/%%SmartyNocache:11353554f33a0b12c39_38927265%%*/ -"; -echo '/*%%SmartyNocache:11353554f33a0b12c39_38927265%%*/tpl_vars[\'default\']->value;?> -/*/%%SmartyNocache:11353554f33a0b12c39_38927265%%*/';?> - 1),$_smarty_tpl);?> -/*/%%SmartyNocache:11353554f33a0b12c39_38927265%%*/'; -echo "/*%%SmartyNocache:11353554f33a0b12c39_38927265%%*/ \$value){ -if (\$_smarty_tpl->tpl_vars[\$key] === \$value) \$saved_tpl_vars[\$key] = \$value; -} -\$_smarty_tpl->tpl_vars = \$saved_tpl_vars;?> -/*/%%SmartyNocache:11353554f33a0b12c39_38927265%%*/"; -?>properties['nocache_hash'], ob_get_clean()); -$_smarty_tpl->tpl_vars = array_pop($_smarty_tpl->properties['saved_tpl_vars']); -} -} -/*/ smarty_template_function_functest_11353554f33a0b12c39_38927265_nocache */ -/* smarty_template_function_functest_11353554f33a0b12c39_38927265 */ -if (!function_exists('smarty_template_function_functest_11353554f33a0b12c39_38927265')) { -function smarty_template_function_functest_11353554f33a0b12c39_38927265($_smarty_tpl,$params) { -if (!is_callable('smarty_function_counter')) require_once 'C:/wamp/www/Smarty3.1-test-release/vendor/smarty/smarty/libs/plugins/function.counter.php'; -$saved_tpl_vars = $_smarty_tpl->tpl_vars; -$params = array_merge(array('default'=>'default'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['default']->value;?> - 1),$_smarty_tpl); -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest_11353554f33a0b12c39_38927265 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6cb7077cbab7f8057647b7b11f55f38f2da9dc36_0.file.test_template_function_tag2.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6cb7077cbab7f8057647b7b11f55f38f2da9dc36_0.file.test_template_function_tag2.tpl.php deleted file mode 100644 index a8baf665..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6cb7077cbab7f8057647b7b11f55f38f2da9dc36_0.file.test_template_function_tag2.tpl.php +++ /dev/null @@ -1,69 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '6cb7077cbab7f8057647b7b11f55f38f2da9dc36' => - array ( - 0 => './templates/test_template_function_tag2.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '20735554f33a1198368_16340485', - 'variables' => - array ( - 'default' => 0, - 'param' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a11cbff7_75513815', - 'tpl_function' => - array ( - 'functest2' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/6cb7077cbab7f8057647b7b11f55f38f2da9dc36_0.file.test_template_function_tag2.tpl.php', - 'uid' => '6cb7077cbab7f8057647b7b11f55f38f2da9dc36', - 'call_name' => 'smarty_template_function_functest2_20735554f33a1198368_16340485', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a11cbff7_75513815')) { -function content_554f33a11cbff7_75513815 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '20735554f33a1198368_16340485'; -$_smarty_tpl->callTemplateFunction ('functest2', $_smarty_tpl, array('param'=>'param'), true);?> - callTemplateFunction ('functest2', $_smarty_tpl, array('param'=>'param2'), true);?> - callTemplateFunction ('functest2', $_smarty_tpl, array('param'=>'param2','default'=>'passed'), true);?> - callTemplateFunction ('functest2', $_smarty_tpl, array('param'=>'param'), true);?> -tpl_vars; -$params = array_merge(array('default'=>'default'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['default']->value;?> - tpl_vars['param']->value; -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest2_20735554f33a1198368_16340485 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php deleted file mode 100644 index 57a61c68..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php +++ /dev/null @@ -1,97 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '6df2384df0a3755f460437207bf362b39a168f74' => - array ( - 0 => './templates/test_template_function_002.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '32163554f33a03b9d17_30936283', - 'variables' => - array ( - 'default' => 0, - 'param' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a03f2984_15922471', - 'tpl_function' => - array ( - 'functest' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/6df2384df0a3755f460437207bf362b39a168f74_0.file.test_template_function_002.tpl.cache.php', - 'uid' => '6df2384df0a3755f460437207bf362b39a168f74', - 'call_name_caching' => 'smarty_template_function_functest_32163554f33a03b9d17_30936283_nocache', - 'call_name' => 'smarty_template_function_functest_32163554f33a03b9d17_30936283', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a03f2984_15922471')) { -function content_554f33a03f2984_15922471 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '32163554f33a03b9d17_30936283'; -$_smarty_tpl->callTemplateFunction ('functest', $_smarty_tpl, array('param'=>'param'), false);?> - callTemplateFunction ('functest', $_smarty_tpl, array('param'=>$_smarty_tpl->tpl_vars['param']->value), false);?> - callTemplateFunction ('functest', $_smarty_tpl, array('param'=>$_smarty_tpl->tpl_vars['param']->value,'default'=>$_smarty_tpl->tpl_vars['default']->value), false);?> -'default'), $params); -$_smarty_tpl->properties['saved_tpl_vars'][] = $_smarty_tpl->tpl_vars; -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -}$params = var_export($params, true); -echo "/*%%SmartyNocache:32163554f33a03b9d17_30936283%%*/tpl_vars; -foreach ($params as \$key => \$value) { -\$_smarty_tpl->tpl_vars[\$key] = new Smarty_Variable(\$value); -} -?>/*/%%SmartyNocache:32163554f33a03b9d17_30936283%%*/ -"; -echo $_smarty_tpl->tpl_vars['default']->value;?> - tpl_vars[\'param\']->value;?> -/*/%%SmartyNocache:32163554f33a03b9d17_30936283%%*/'; -echo "/*%%SmartyNocache:32163554f33a03b9d17_30936283%%*/ \$value){ -if (\$_smarty_tpl->tpl_vars[\$key] === \$value) \$saved_tpl_vars[\$key] = \$value; -} -\$_smarty_tpl->tpl_vars = \$saved_tpl_vars;?> -/*/%%SmartyNocache:32163554f33a03b9d17_30936283%%*/"; -?>properties['nocache_hash'], ob_get_clean()); -$_smarty_tpl->tpl_vars = array_pop($_smarty_tpl->properties['saved_tpl_vars']); -} -} -/*/ smarty_template_function_functest_32163554f33a03b9d17_30936283_nocache */ -/* smarty_template_function_functest_32163554f33a03b9d17_30936283 */ -if (!function_exists('smarty_template_function_functest_32163554f33a03b9d17_30936283')) { -function smarty_template_function_functest_32163554f33a03b9d17_30936283($_smarty_tpl,$params) { -$saved_tpl_vars = $_smarty_tpl->tpl_vars; -$params = array_merge(array('default'=>'default'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['default']->value;?> - tpl_vars['param']->value; -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest_32163554f33a03b9d17_30936283 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_0.file.test_template_function_tag5.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_0.file.test_template_function_tag5.tpl.php deleted file mode 100644 index 11e2234e..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_0.file.test_template_function_tag5.tpl.php +++ /dev/null @@ -1,68 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '743d0e59177f943e67ac0f2a52c3e77d787a7b98' => - array ( - 0 => './templates/test_template_function_tag5.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '13589554f33a1739657_70054575', - 'variables' => - array ( - 'loop' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a17645a9_04761730', - 'tpl_function' => - array ( - 'functest4' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_0.file.test_template_function_tag5.tpl.php', - 'uid' => '743d0e59177f943e67ac0f2a52c3e77d787a7b98', - 'call_name' => 'smarty_template_function_functest4_13589554f33a1739657_70054575', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a17645a9_04761730')) { -function content_554f33a17645a9_04761730 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '13589554f33a1739657_70054575'; -echo $_smarty_tpl->getSubTemplate ('test_inherit_function_tag.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0); -?> -tpl_vars; -$params = array_merge(array('loop'=>0), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['loop']->value; -if ($_smarty_tpl->tpl_vars['loop']->value<5) { -$_smarty_tpl->callTemplateFunction ('functest4', $_smarty_tpl, array('loop'=>$_smarty_tpl->tpl_vars['loop']->value+1), false); -} -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest4_13589554f33a1739657_70054575 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_1.file.test_template_function_tag5.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_1.file.test_template_function_tag5.tpl.php deleted file mode 100644 index 094b4fbf..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_1.file.test_template_function_tag5.tpl.php +++ /dev/null @@ -1,87 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '743d0e59177f943e67ac0f2a52c3e77d787a7b98' => - array ( - 0 => './templates/test_template_function_tag5.tpl', - 1 => 1430802407, - 2 => 'file', - ), - 'd0ce3d3da7d8c86b14875fc36c9fccde5dc190ba' => - array ( - 0 => './templates/test_inherit_function_tag.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '32283554f33a1a4e286_12401978', - 'variables' => - array ( - 'loop' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a1a80068_05590904', - 'tpl_function' => - array ( - 'functest4' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/743d0e59177f943e67ac0f2a52c3e77d787a7b98_1.file.test_template_function_tag5.tpl.php', - 'uid' => '743d0e59177f943e67ac0f2a52c3e77d787a7b98', - 'call_name' => 'smarty_template_function_functest4_32283554f33a1a4e286_12401978', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a1a80068_05590904')) { -function content_554f33a1a80068_05590904 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '32283554f33a1a4e286_12401978'; -/* Call merged included template "test_inherit_function_tag.tpl" */ -echo $_smarty_tpl->getInlineSubTemplate('test_inherit_function_tag.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0, '3473554f33a1a78440_81337556', 'content_554f33a1a77345_73752731'); -/* End of included template "test_inherit_function_tag.tpl" */?> - -properties['nocache_hash'] = '3473554f33a1a78440_81337556'; -$_smarty_tpl->callTemplateFunction ('functest4', $_smarty_tpl, array(), true);?> -tpl_vars; -$params = array_merge(array('loop'=>0), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['loop']->value; -if ($_smarty_tpl->tpl_vars['loop']->value<5) { -$_smarty_tpl->callTemplateFunction ('functest4', $_smarty_tpl, array('loop'=>$_smarty_tpl->tpl_vars['loop']->value+1), false); -} -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest4_32283554f33a1a4e286_12401978 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_0.file.test_template_function_tag6.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_0.file.test_template_function_tag6.tpl.php deleted file mode 100644 index 997619a8..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_0.file.test_template_function_tag6.tpl.php +++ /dev/null @@ -1,32 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '7ab850c40341ef728a2c3a36cf62b7880b023d06' => - array ( - 0 => './templates/test_template_function_tag6.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '9462554f33a1d2ad82_45742097', - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a1d35a35_68706146', -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a1d35a35_68706146')) { -function content_554f33a1d35a35_68706146 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '9462554f33a1d2ad82_45742097'; -echo $_smarty_tpl->getSubTemplate ('test_define_function_tag.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0); -echo $_smarty_tpl->getSubTemplate ('test_inherit_function_tag6.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0); -?> - \ No newline at end of file diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_1.file.test_template_function_tag6.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_1.file.test_template_function_tag6.tpl.php deleted file mode 100644 index d0fe72b5..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_1.file.test_template_function_tag6.tpl.php +++ /dev/null @@ -1,104 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '7ab850c40341ef728a2c3a36cf62b7880b023d06' => - array ( - 0 => './templates/test_template_function_tag6.tpl', - 1 => 1430802407, - 2 => 'file', - ), - '2e9582e4d4f31291755140d7b123bc17fbaa811a' => - array ( - 0 => './templates/test_define_function_tag.tpl', - 1 => 1430802407, - 2 => 'file', - ), - 'c43995ee759c6c7f171e915aace16ee91ee059a9' => - array ( - 0 => './templates/test_inherit_function_tag6.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '29133554f33a2200012_48386613', - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a223ad46_61545179', - 'tpl_function' => - array ( - 'functest6i' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/7ab850c40341ef728a2c3a36cf62b7880b023d06_1.file.test_template_function_tag6.tpl.php', - 'uid' => '2e9582e4d4f31291755140d7b123bc17fbaa811a', - 'call_name' => 'smarty_template_function_functest6i_5523554f33a22066a1_70467432', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a223ad46_61545179')) { -function content_554f33a223ad46_61545179 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '29133554f33a2200012_48386613'; -/* Call merged included template "test_define_function_tag.tpl" */ -echo $_smarty_tpl->getInlineSubTemplate('test_define_function_tag.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0, '5523554f33a22066a1_70467432', 'content_554f33a2205710_05709812'); -/* End of included template "test_define_function_tag.tpl" */ -/* Call merged included template "test_inherit_function_tag6.tpl" */ -echo $_smarty_tpl->getInlineSubTemplate('test_inherit_function_tag6.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0, '24009554f33a2232320_32744838', 'content_554f33a2231111_07613734'); -/* End of included template "test_inherit_function_tag6.tpl" */?> - -properties['nocache_hash'] = '5523554f33a22066a1_70467432'; -?> - -properties['nocache_hash'] = '24009554f33a2232320_32744838'; -$_smarty_tpl->callTemplateFunction ('functest6i', $_smarty_tpl, array(), true);?> -tpl_vars; -$params = array_merge(array('loop'=>0), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['loop']->value; -if ($_smarty_tpl->tpl_vars['loop']->value<5) { -$_smarty_tpl->callTemplateFunction ('functest6i', $_smarty_tpl, array('loop'=>$_smarty_tpl->tpl_vars['loop']->value+1), false); -} -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest6i_5523554f33a22066a1_70467432 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_0.file.test_template_function_nocache_call.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_0.file.test_template_function_nocache_call.tpl.cache.php deleted file mode 100644 index 6ecf5b1d..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_0.file.test_template_function_nocache_call.tpl.cache.php +++ /dev/null @@ -1,32 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61' => - array ( - 0 => './templates/test_template_function_nocache_call.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '9227554f33a309a449_19754931', - 'has_nocache_code' => true, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a30a7084_73390220', -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a30a7084_73390220')) { -function content_554f33a30a7084_73390220 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '9227554f33a309a449_19754931'; -echo $_smarty_tpl->getSubTemplate ('template_function_lib.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 9999, $_smarty_tpl->cache_lifetime, array(), 0); -echo '/*%%SmartyNocache:9227554f33a309a449_19754931%%*/callTemplateFunction (\'template_func1\', $_smarty_tpl, array(), true);?> -/*/%%SmartyNocache:9227554f33a309a449_19754931%%*/';?> - \ No newline at end of file diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_1.file.test_template_function_nocache_call.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_1.file.test_template_function_nocache_call.tpl.cache.php deleted file mode 100644 index 61e15921..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_1.file.test_template_function_nocache_call.tpl.cache.php +++ /dev/null @@ -1,113 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61' => - array ( - 0 => './templates/test_template_function_nocache_call.tpl', - 1 => 1430802407, - 2 => 'file', - ), - 'dfb143ec1fbcb556e13ac1f174c3b8394191bd18' => - array ( - 0 => './templates/template_function_lib.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '25320554f33a336e935_85019970', - 'has_nocache_code' => true, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a33a5381_95773343', - 'tpl_function' => - array ( - 'template_func1' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/7fe6a2a43aee3e8dbfe08235cf00ef0c2bdd4a61_1.file.test_template_function_nocache_call.tpl.cache.php', - 'uid' => 'dfb143ec1fbcb556e13ac1f174c3b8394191bd18', - 'call_name_caching' => 'smarty_template_function_template_func1_14246554f33a33751a3_10584105_nocache', - 'call_name' => 'smarty_template_function_template_func1_14246554f33a33751a3_10584105', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a33a5381_95773343')) { -function content_554f33a33a5381_95773343 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '25320554f33a336e935_85019970'; -/* Call merged included template "template_function_lib.tpl" */ -echo $_smarty_tpl->getInlineSubTemplate('template_function_lib.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 9999, $_smarty_tpl->cache_lifetime, array(), 0, '14246554f33a33751a3_10584105', 'content_554f33a3374104_61765255'); -/* End of included template "template_function_lib.tpl" */ -echo '/*%%SmartyNocache:25320554f33a336e935_85019970%%*/callTemplateFunction (\'template_func1\', $_smarty_tpl, array(), true);?> -/*/%%SmartyNocache:25320554f33a336e935_85019970%%*/';?> - -properties['nocache_hash'] = '14246554f33a33751a3_10584105'; -?> - -'d1'), $params); -$_smarty_tpl->properties['saved_tpl_vars'][] = $_smarty_tpl->tpl_vars; -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -}$params = var_export($params, true); -echo "/*%%SmartyNocache:14246554f33a33751a3_10584105%%*/tpl_vars; -foreach ($params as \$key => \$value) { -\$_smarty_tpl->tpl_vars[\$key] = new Smarty_Variable(\$value); -} -?>/*/%%SmartyNocache:14246554f33a33751a3_10584105%%*/ -"; -echo htmlspecialchars($_smarty_tpl->tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true);?> - tpl_vars[\'foo\']->value, ENT_QUOTES, \'UTF-8\', true);?> -/*/%%SmartyNocache:14246554f33a33751a3_10584105%%*/';?> - \$value){ -if (\$_smarty_tpl->tpl_vars[\$key] === \$value) \$saved_tpl_vars[\$key] = \$value; -} -\$_smarty_tpl->tpl_vars = \$saved_tpl_vars;?> -/*/%%SmartyNocache:14246554f33a33751a3_10584105%%*/"; -?>properties['nocache_hash'], ob_get_clean()); -$_smarty_tpl->tpl_vars = array_pop($_smarty_tpl->properties['saved_tpl_vars']); -} -} -/*/ smarty_template_function_template_func1_14246554f33a33751a3_10584105_nocache */ -/* smarty_template_function_template_func1_14246554f33a33751a3_10584105 */ -if (!function_exists('smarty_template_function_template_func1_14246554f33a33751a3_10584105')) { -function smarty_template_function_template_func1_14246554f33a33751a3_10584105($_smarty_tpl,$params) { -$saved_tpl_vars = $_smarty_tpl->tpl_vars; -$params = array_merge(array('default'=>'d1'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo htmlspecialchars($_smarty_tpl->tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true);?> - tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true); -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_template_func1_14246554f33a33751a3_10584105 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_0.file.test_template_function.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_0.file.test_template_function.tpl.cache.php deleted file mode 100644 index 4708cfab..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_0.file.test_template_function.tpl.cache.php +++ /dev/null @@ -1,31 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '9d9c162f1a2d1af75355a54fa37e85b832d9728a' => - array ( - 0 => './templates/test_template_function.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '23758554f33a24e2527_45120061', - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a24ed0e0_77310981', -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a24ed0e0_77310981')) { -function content_554f33a24ed0e0_77310981 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '23758554f33a24e2527_45120061'; -echo $_smarty_tpl->getSubTemplate ('template_function_lib.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 9999, $_smarty_tpl->cache_lifetime, array(), 0); -$_smarty_tpl->callTemplateFunction ('template_func1', $_smarty_tpl, array(), false);?> - \ No newline at end of file diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_1.file.test_template_function.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_1.file.test_template_function.tpl.cache.php deleted file mode 100644 index 6567126e..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_1.file.test_template_function.tpl.cache.php +++ /dev/null @@ -1,112 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - '9d9c162f1a2d1af75355a54fa37e85b832d9728a' => - array ( - 0 => './templates/test_template_function.tpl', - 1 => 1430802407, - 2 => 'file', - ), - 'dfb143ec1fbcb556e13ac1f174c3b8394191bd18' => - array ( - 0 => './templates/template_function_lib.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '4860554f33a2834c32_19980616', - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a28651d5_62401584', - 'tpl_function' => - array ( - 'template_func1' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/9d9c162f1a2d1af75355a54fa37e85b832d9728a_1.file.test_template_function.tpl.cache.php', - 'uid' => 'dfb143ec1fbcb556e13ac1f174c3b8394191bd18', - 'call_name_caching' => 'smarty_template_function_template_func1_30682554f33a283b093_35547451_nocache', - 'call_name' => 'smarty_template_function_template_func1_30682554f33a283b093_35547451', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a28651d5_62401584')) { -function content_554f33a28651d5_62401584 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '4860554f33a2834c32_19980616'; -/* Call merged included template "template_function_lib.tpl" */ -echo $_smarty_tpl->getInlineSubTemplate('template_function_lib.tpl', $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 9999, $_smarty_tpl->cache_lifetime, array(), 0, '30682554f33a283b093_35547451', 'content_554f33a283a179_89560857'); -/* End of included template "template_function_lib.tpl" */ -$_smarty_tpl->callTemplateFunction ('template_func1', $_smarty_tpl, array(), false);?> - -properties['nocache_hash'] = '30682554f33a283b093_35547451'; -?> - -'d1'), $params); -$_smarty_tpl->properties['saved_tpl_vars'][] = $_smarty_tpl->tpl_vars; -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -}$params = var_export($params, true); -echo "/*%%SmartyNocache:30682554f33a283b093_35547451%%*/tpl_vars; -foreach ($params as \$key => \$value) { -\$_smarty_tpl->tpl_vars[\$key] = new Smarty_Variable(\$value); -} -?>/*/%%SmartyNocache:30682554f33a283b093_35547451%%*/ -"; -echo htmlspecialchars($_smarty_tpl->tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true);?> - tpl_vars[\'foo\']->value, ENT_QUOTES, \'UTF-8\', true);?> -/*/%%SmartyNocache:30682554f33a283b093_35547451%%*/';?> - \$value){ -if (\$_smarty_tpl->tpl_vars[\$key] === \$value) \$saved_tpl_vars[\$key] = \$value; -} -\$_smarty_tpl->tpl_vars = \$saved_tpl_vars;?> -/*/%%SmartyNocache:30682554f33a283b093_35547451%%*/"; -?>properties['nocache_hash'], ob_get_clean()); -$_smarty_tpl->tpl_vars = array_pop($_smarty_tpl->properties['saved_tpl_vars']); -} -} -/*/ smarty_template_function_template_func1_30682554f33a283b093_35547451_nocache */ -/* smarty_template_function_template_func1_30682554f33a283b093_35547451 */ -if (!function_exists('smarty_template_function_template_func1_30682554f33a283b093_35547451')) { -function smarty_template_function_template_func1_30682554f33a283b093_35547451($_smarty_tpl,$params) { -$saved_tpl_vars = $_smarty_tpl->tpl_vars; -$params = array_merge(array('default'=>'d1'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo htmlspecialchars($_smarty_tpl->tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true);?> - tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true); -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_template_func1_30682554f33a283b093_35547451 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/c43995ee759c6c7f171e915aace16ee91ee059a9_0.file.test_inherit_function_tag6.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/c43995ee759c6c7f171e915aace16ee91ee059a9_0.file.test_inherit_function_tag6.tpl.php deleted file mode 100644 index d6c8d8a3..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/c43995ee759c6c7f171e915aace16ee91ee059a9_0.file.test_inherit_function_tag6.tpl.php +++ /dev/null @@ -1,30 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - 'c43995ee759c6c7f171e915aace16ee91ee059a9' => - array ( - 0 => './templates/test_inherit_function_tag6.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '15204554f33a1de0580_19542266', - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a1de7249_10070278', -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a1de7249_10070278')) { -function content_554f33a1de7249_10070278 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '15204554f33a1de0580_19542266'; -$_smarty_tpl->callTemplateFunction ('functest6i', $_smarty_tpl, array(), true);?> - \ No newline at end of file diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d0ce3d3da7d8c86b14875fc36c9fccde5dc190ba_0.file.test_inherit_function_tag.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d0ce3d3da7d8c86b14875fc36c9fccde5dc190ba_0.file.test_inherit_function_tag.tpl.php deleted file mode 100644 index 6beb3378..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d0ce3d3da7d8c86b14875fc36c9fccde5dc190ba_0.file.test_inherit_function_tag.tpl.php +++ /dev/null @@ -1,30 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - 'd0ce3d3da7d8c86b14875fc36c9fccde5dc190ba' => - array ( - 0 => './templates/test_inherit_function_tag.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '12330554f33a17a8e57_80091046', - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a17b2c42_44491970', -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a17b2c42_44491970')) { -function content_554f33a17b2c42_44491970 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '12330554f33a17a8e57_80091046'; -$_smarty_tpl->callTemplateFunction ('functest4', $_smarty_tpl, array(), true);?> - \ No newline at end of file diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.cache.php deleted file mode 100644 index af97c2e3..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.cache.php +++ /dev/null @@ -1,68 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - 'd80ab133a083b4a7b15480731cf13d1c48e9f54a' => - array ( - 0 => './templates/test_template_function_001.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '22738554f33a00aae61_12933950', - 'variables' => - array ( - 'default' => 0, - 'param' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a00dc9b8_87833168', - 'tpl_function' => - array ( - 'functest' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.cache.php', - 'uid' => 'd80ab133a083b4a7b15480731cf13d1c48e9f54a', - 'call_name' => 'smarty_template_function_functest_22738554f33a00aae61_12933950', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a00dc9b8_87833168')) { -function content_554f33a00dc9b8_87833168 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '22738554f33a00aae61_12933950'; -$_smarty_tpl->callTemplateFunction ('functest', $_smarty_tpl, array('param'=>'param'), false);?> - callTemplateFunction ('functest', $_smarty_tpl, array('param'=>$_smarty_tpl->tpl_vars['param']->value), false);?> - callTemplateFunction ('functest', $_smarty_tpl, array('param'=>$_smarty_tpl->tpl_vars['param']->value,'default'=>$_smarty_tpl->tpl_vars['default']->value), false);?> -tpl_vars; -$params = array_merge(array('default'=>'default'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['default']->value;?> - tpl_vars['param']->value; -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest_22738554f33a00aae61_12933950 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.php deleted file mode 100644 index a7724ed5..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.php +++ /dev/null @@ -1,68 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - 'd80ab133a083b4a7b15480731cf13d1c48e9f54a' => - array ( - 0 => './templates/test_template_function_001.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '30557554f339fd13129_70091209', - 'variables' => - array ( - 'default' => 0, - 'param' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f339fd4d089_46348959', - 'tpl_function' => - array ( - 'functest' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/d80ab133a083b4a7b15480731cf13d1c48e9f54a_0.file.test_template_function_001.tpl.php', - 'uid' => 'd80ab133a083b4a7b15480731cf13d1c48e9f54a', - 'call_name' => 'smarty_template_function_functest_30557554f339fd13129_70091209', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f339fd4d089_46348959')) { -function content_554f339fd4d089_46348959 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '30557554f339fd13129_70091209'; -$_smarty_tpl->callTemplateFunction ('functest', $_smarty_tpl, array('param'=>'param'), true);?> - callTemplateFunction ('functest', $_smarty_tpl, array('param'=>$_smarty_tpl->tpl_vars['param']->value), true);?> - callTemplateFunction ('functest', $_smarty_tpl, array('param'=>$_smarty_tpl->tpl_vars['param']->value,'default'=>$_smarty_tpl->tpl_vars['default']->value), true);?> -tpl_vars; -$params = array_merge(array('default'=>'default'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['default']->value;?> - tpl_vars['param']->value; -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest_30557554f339fd13129_70091209 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/dfb143ec1fbcb556e13ac1f174c3b8394191bd18_0.file.template_function_lib.tpl.cache.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/dfb143ec1fbcb556e13ac1f174c3b8394191bd18_0.file.template_function_lib.tpl.cache.php deleted file mode 100644 index 0c585700..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/dfb143ec1fbcb556e13ac1f174c3b8394191bd18_0.file.template_function_lib.tpl.cache.php +++ /dev/null @@ -1,95 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - 'dfb143ec1fbcb556e13ac1f174c3b8394191bd18' => - array ( - 0 => './templates/template_function_lib.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '30703554f33a2534bd6_18319841', - 'variables' => - array ( - 'foo' => 1, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a255bc18_48320158', - 'tpl_function' => - array ( - 'template_func1' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/dfb143ec1fbcb556e13ac1f174c3b8394191bd18_0.file.template_function_lib.tpl.cache.php', - 'uid' => 'dfb143ec1fbcb556e13ac1f174c3b8394191bd18', - 'call_name_caching' => 'smarty_template_function_template_func1_30703554f33a2534bd6_18319841_nocache', - 'call_name' => 'smarty_template_function_template_func1_30703554f33a2534bd6_18319841', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a255bc18_48320158')) { -function content_554f33a255bc18_48320158 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '30703554f33a2534bd6_18319841'; -?> - -'d1'), $params); -$_smarty_tpl->properties['saved_tpl_vars'][] = $_smarty_tpl->tpl_vars; -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -}$params = var_export($params, true); -echo "/*%%SmartyNocache:30703554f33a2534bd6_18319841%%*/tpl_vars; -foreach ($params as \$key => \$value) { -\$_smarty_tpl->tpl_vars[\$key] = new Smarty_Variable(\$value); -} -?>/*/%%SmartyNocache:30703554f33a2534bd6_18319841%%*/ -"; -echo htmlspecialchars($_smarty_tpl->tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true);?> - tpl_vars[\'foo\']->value, ENT_QUOTES, \'UTF-8\', true);?> -/*/%%SmartyNocache:30703554f33a2534bd6_18319841%%*/';?> - \$value){ -if (\$_smarty_tpl->tpl_vars[\$key] === \$value) \$saved_tpl_vars[\$key] = \$value; -} -\$_smarty_tpl->tpl_vars = \$saved_tpl_vars;?> -/*/%%SmartyNocache:30703554f33a2534bd6_18319841%%*/"; -?>properties['nocache_hash'], ob_get_clean()); -$_smarty_tpl->tpl_vars = array_pop($_smarty_tpl->properties['saved_tpl_vars']); -} -} -/*/ smarty_template_function_template_func1_30703554f33a2534bd6_18319841_nocache */ -/* smarty_template_function_template_func1_30703554f33a2534bd6_18319841 */ -if (!function_exists('smarty_template_function_template_func1_30703554f33a2534bd6_18319841')) { -function smarty_template_function_template_func1_30703554f33a2534bd6_18319841($_smarty_tpl,$params) { -$saved_tpl_vars = $_smarty_tpl->tpl_vars; -$params = array_merge(array('default'=>'d1'), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo htmlspecialchars($_smarty_tpl->tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true);?> - tpl_vars['foo']->value, ENT_QUOTES, 'UTF-8', true); -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_template_func1_30703554f33a2534bd6_18319841 */ - -?> diff --git a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/f07aa3eeb4dea4c19bbd2f4c2ae3f28f1776589c_0.file.test_template_function_tag4.tpl.php b/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/f07aa3eeb4dea4c19bbd2f4c2ae3f28f1776589c_0.file.test_template_function_tag4.tpl.php deleted file mode 100644 index 0de9e5fe..00000000 --- a/tests/UnitTests/TemplateSource/TagTests/TemplateFunction/templates_c/f07aa3eeb4dea4c19bbd2f4c2ae3f28f1776589c_0.file.test_template_function_tag4.tpl.php +++ /dev/null @@ -1,67 +0,0 @@ - -decodeProperties(array ( - 'file_dependency' => - array ( - 'f07aa3eeb4dea4c19bbd2f4c2ae3f28f1776589c' => - array ( - 0 => './templates/test_template_function_tag4.tpl', - 1 => 1430802407, - 2 => 'file', - ), - ), - 'nocache_hash' => '24268554f33a14620b8_97298192', - 'variables' => - array ( - 'loop' => 0, - ), - 'has_nocache_code' => false, - 'version' => '3.1.22-dev/32', - 'unifunc' => 'content_554f33a148afb4_17621827', - 'tpl_function' => - array ( - 'functest4' => - array ( - 'called_functions' => - array ( - ), - 'compiled_filepath' => './templates_c/f07aa3eeb4dea4c19bbd2f4c2ae3f28f1776589c_0.file.test_template_function_tag4.tpl.php', - 'uid' => 'f07aa3eeb4dea4c19bbd2f4c2ae3f28f1776589c', - 'call_name' => 'smarty_template_function_functest4_24268554f33a14620b8_97298192', - ), - ), -),false); -/*/%%SmartyHeaderCode%%*/ -if ($_valid && !is_callable('content_554f33a148afb4_17621827')) { -function content_554f33a148afb4_17621827 ($_smarty_tpl) { -?> -properties['nocache_hash'] = '24268554f33a14620b8_97298192'; -$_smarty_tpl->callTemplateFunction ('functest4', $_smarty_tpl, array(), true);?> -tpl_vars; -$params = array_merge(array('loop'=>0), $params); -foreach ($params as $key => $value) { -$_smarty_tpl->tpl_vars[$key] = new Smarty_Variable($value); -} -echo $_smarty_tpl->tpl_vars['loop']->value; -if ($_smarty_tpl->tpl_vars['loop']->value<5) { -$_smarty_tpl->callTemplateFunction ('functest4', $_smarty_tpl, array('loop'=>$_smarty_tpl->tpl_vars['loop']->value+1), false); -} -foreach (Smarty::$global_tpl_vars as $key => $value){ -if ($_smarty_tpl->tpl_vars[$key] === $value) $saved_tpl_vars[$key] = $value; -} -$_smarty_tpl->tpl_vars = $saved_tpl_vars; -} -} -/*/ smarty_template_function_functest4_24268554f33a14620b8_97298192 */ - -?>