Merge PR #1194 branch 'marc1706/ticket/11323' into develop-olympus

# By Marc Alexander
# Via Marc Alexander
* marc1706/ticket/11323:
  [ticket/11323] Add tests for inclusion of defined variables
This commit is contained in:
Oleg Pudeyev 2013-01-13 20:11:31 -05:00
commit 227f7f46df
3 changed files with 22 additions and 1 deletions

View file

@ -238,7 +238,22 @@ class phpbb_template_template_test extends phpbb_test_case
array('loop' => array(array('VARIABLE' => 'x'), array('VARIABLE' => 'y')), 'loop.inner' => array(array(), array())),
array('loop'),
'',
),/* no top level nested loops
),
array(
'include_define_variable.html',
array('VARIABLE' => 'variable.html'),
array(),
array(),
'variable.html',
),
array(
'include_loop_define.html',
array('VARIABLE' => 'value'),
array('loop' => array(array('NESTED_FILE' => 'variable.html'))),
array(),
'value',
),
/* no top level nested loops
array(
'loop_vars.html',
array(),

View file

@ -0,0 +1,2 @@
<!-- DEFINE $DEF = '{VARIABLE}' -->
<!-- INCLUDE {$DEF} -->

View file

@ -0,0 +1,4 @@
<!-- BEGIN loop -->
<!-- DEFINE $DEF = '{loop.NESTED_FILE}' -->
<!-- INCLUDE {$DEF} -->
<!-- END loop -->