compiler = new Dwoo_Compiler();
$this->dwoo = new Dwoo_Core(DWOO_COMPILE_DIR, DWOO_CACHE_DIR);
}
public function testHtmlFormat()
{
$tpl = new Dwoo_Template_String("
");
$tpl->forceCompilation();
$dwoo = new Dwoo_Core(DWOO_COMPILE_DIR, DWOO_CACHE_DIR);
$dwoo->addFilter('html_format', true);
$this->assertEquals(str_replace("\r", '', <<
SNIPPET
), $dwoo->get($tpl, array(), $this->compiler));
}
public function testSmartyCompat()
{
$tpl = new Dwoo_Template_String('{ldelim}{$smarty.version}{rdelim}');
$tpl->forceCompilation();
$cmp = new Dwoo_Compiler();
$cmp->addPreProcessor('smarty_compat', true);
$this->assertEquals('{'.Dwoo_Core::VERSION.'}', $this->dwoo->get($tpl, array(), $cmp));
}
}