/** * @test * @expectedException \RuntimeException */ public function updateRootlineDataWithInvalidNewRootlineThrowsException() { $originalRootline = array(0 => array('uid' => 2, 'title' => 'originalTitle'), 1 => array('uid' => 3, 'title' => 'originalTitle2')); $newInvalidRootline = array(0 => array('uid' => 1, 'title' => 'newTitle'), 1 => array('uid' => 2, 'title' => 'newTitle2')); $this->templateServiceMock->_set('rootLine', $originalRootline); $this->templateServiceMock->updateRootlineData($newInvalidRootline); }
/** * Updating content of the two rootLines IF the language key is set! */ protected function updateRootLinesWithTranslations() { if ($this->sys_language_uid) { $this->rootLine = $this->sys_page->getRootLine($this->id, $this->MP); $this->tmpl->updateRootlineData($this->rootLine); } }