aboutsummaryrefslogtreecommitdiffstats
path: root/tests/template/template_includejs_test.php
diff options
context:
space:
mode:
authorFyorl <gaelreth@gmail.com>2012-07-07 22:43:52 +0100
committerFyorl <gaelreth@gmail.com>2012-07-08 20:41:00 +0100
commitd5896239068e1063970f398a12ffb5a0707fb286 (patch)
tree2cecbff20e71e466412cadbb7f49c52044a0b244 /tests/template/template_includejs_test.php
parent576cd6dd1e45171e998d6aa13ab74b73939ce084 (diff)
downloadforums-d5896239068e1063970f398a12ffb5a0707fb286.tar
forums-d5896239068e1063970f398a12ffb5a0707fb286.tar.gz
forums-d5896239068e1063970f398a12ffb5a0707fb286.tar.bz2
forums-d5896239068e1063970f398a12ffb5a0707fb286.tar.xz
forums-d5896239068e1063970f398a12ffb5a0707fb286.zip
[ticket/10970] Paths of the form {FOO}/a/{BAR}/b parsed correctly
A new method to handle this type of path was added and compile_tag_include, compile_tag_include_php and compile_tag_include_js were modified to use it appropriately. Tests were added for these three macros also. PHPBB3-10970
Diffstat (limited to 'tests/template/template_includejs_test.php')
-rw-r--r--tests/template/template_includejs_test.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/template/template_includejs_test.php b/tests/template/template_includejs_test.php
index a8f9a9037f..d8c7170e94 100644
--- a/tests/template/template_includejs_test.php
+++ b/tests/template/template_includejs_test.php
@@ -20,11 +20,13 @@ class phpbb_template_template_includejs_test extends phpbb_template_template_tes
$scripts = array(
'<script src="' . $this->test_path . '/templates/parent_and_child.js?assets_version=1"></script>',
'<script src="' . $this->test_path . '/parent_templates/parent_only.js?assets_version=1"></script>',
- '<script src="' . $this->test_path . '/templates/child_only.js?assets_version=1"></script>'
+ '<script src="' . $this->test_path . '/templates/child_only.js?assets_version=1"></script>',
+ '<script src="' . $this->test_path . '/templates/subdir/parent_only.js?assets_version=1"></script>',
+ '<script src="' . $this->test_path . '/templates/subdir/subsubdir/parent_only.js?assets_version=1"></script>',
);
// Run test
$cache_file = $this->template->cachepath . 'includejs.html.php';
- $this->run_template('includejs.html', array('PARENT' => 'parent_only.js'), array(), array(), implode('', $scripts), $cache_file);
+ $this->run_template('includejs.html', array('PARENT' => 'parent_only.js', 'SUBDIR' => 'subdir'), array(), array(), implode('', $scripts), $cache_file);
}
}