compileCode($code, "inline.tpl"); if($dump) { echo "\n===========================\n".$code.": ".$tpl->getBody(); } $this->assertSame(Modifier::strip($result), Modifier::strip($tpl->fetch($vars), true), "Test $code"); } public function execError($code, $exception, $message, $options) { self::$aspect->setOptions($options); try { self::$aspect->compileCode($code, "inline.tpl"); } catch(\Exception $e) { $this->assertSame($exception, get_class($e), "Exception $code"); $this->assertStringStartsWith($message, $e->getMessage()); self::$aspect->setOptions(0); return; } self::$aspect->setOptions(0); $this->fail("Code $code must be invalid"); } /** * @group extends */ public function testParent() { //echo(self::$aspect->getTemplate("parent.tpl")->getBody()); exit; } /** * @group extends */ public function ___testChildLevel1() { echo(self::$aspect->getTemplate("child1.tpl")->getBody()); exit; } /** * @group extends */ public function __testExtends() { echo(self::$aspect->fetch("child1.tpl", array("a" => "value", "z" => ""))."\n"); exit; } }