Update docs
  Add {import ... from ...}
  Improve parsing
This commit is contained in:
bzick
2013-03-14 21:45:00 +04:00
parent 26393ad22d
commit a3c5128aba
15 changed files with 221 additions and 101 deletions

View File

@@ -266,7 +266,7 @@ class TemplateTest extends TestCase {
public static function providerIncludeInvalid() {
return array(
array('Include {include} template', 'Aspect\CompileException', "Unexpected end of expression"),
array('Include {include another="welcome.tpl"} template', 'Aspect\CompileException', "Unexpected token '=' in expression"),
array('Include {include another="welcome.tpl"} template', 'Aspect\CompileException', "Unexpected token '='"),
);
}

View File

@@ -68,6 +68,9 @@ class AspectTest extends \Aspect\TestCase {
$this->assertSame("Custom modifier (myMod)Custom(/myMod)", $this->aspect->fetch('custom.tpl', array("a" => "Custom")));
}
/**
* @group add_functions
*/
public function testSetFunctions() {
$this->aspect->setOptions(Aspect::FORCE_COMPILE);
$this->aspect->addFunction("myfunc", "myFunc");