public function testGetSetId() { $t = new Template(); $this->assertEquals('', $t->getId()); $t->setId('foo'); $this->assertEquals('foo', $t->getId()); }
/** * Add template * * If multiple templates with the same id are added the former is * overwritten * * @param Template $template * @return void */ public function addTemplate(Template $template) { $id = $template->getId(); $this->templates[$id] = $template; }