[feature/twig] template->cachepath is now private, missed checking tests

PHPBB3-11598
This commit is contained in:
Nathaniel Guse 2013-07-02 12:59:23 -05:00
parent 6bbe92a8d0
commit 2507c648fe
2 changed files with 6 additions and 2 deletions

View file

@ -33,11 +33,13 @@ class phpbb_template_includephp_test extends phpbb_template_template_test_case
public function test_includephp_absolute()
{
global $phpbb_root_path;
$path_to_php = str_replace('\\', '/', dirname(__FILE__)) . '/templates/_dummy_include.php.inc';
$this->assertTrue(phpbb_is_absolute($path_to_php));
$template_text = "Path is absolute.\n<!-- INCLUDEPHP $path_to_php -->";
$cache_dir = dirname($this->template->cachepath) . '/';
$cache_dir = dirname($phpbb_root_path . 'cache') . '/';
$fp = fopen($cache_dir . 'includephp_absolute.html', 'w');
fputs($fp, $template_text);
fclose($fp);

View file

@ -371,9 +371,11 @@ class phpbb_template_template_test extends phpbb_template_template_test_case
public function test_php()
{
global $phpbb_root_path;
$template_text = '<!-- PHP -->echo "test";<!-- ENDPHP -->';
$cache_dir = dirname($this->template->cachepath) . '/';
$cache_dir = dirname($phpbb_root_path . 'cache') . '/';
$fp = fopen($cache_dir . 'php.html', 'w');
fputs($fp, $template_text);
fclose($fp);