This commit is contained in:
bzick
2013-08-29 11:29:34 +04:00
parent 270f90792a
commit eef42150b2
5 changed files with 23 additions and 33 deletions

View File

@ -56,6 +56,7 @@ class TestCase extends \PHPUnit_Framework_TestCase
$this->fenom = Fenom::factory(FENOM_RESOURCES . '/template', FENOM_RESOURCES . '/compile');
$this->fenom->addModifier('dots', __CLASS__ . '::dots');
$this->fenom->addModifier('concat', __CLASS__ . '::concat');
$this->fenom->addModifier('append', __CLASS__ . '::append');
$this->fenom->addFunction('test_function', __CLASS__ . '::inlineFunction');
$this->fenom->addBlockFunction('test_block_function', __CLASS__ . '::blockFunction');
}
@ -70,6 +71,12 @@ class TestCase extends \PHPUnit_Framework_TestCase
return call_user_func_array('var_export', func_get_args());
}
public static function append()
{
return implode("", func_get_args());
}
public static function inlineFunction($params)
{
return isset($params["text"]) ? $params["text"] : "";