/** * @expectedException \Oro\Component\Layout\Exception\LogicException * @expectedExceptionMessage Cannot get options for "root" item. Reason: The "root" item does not exist. */ public function testGetOptionsForUnknownItem() { $this->rawLayoutBuilder->getOptions('root'); }
public function testGetParentId() { $this->rawLayoutBuilder->add('root', null, 'root')->add('header', 'root', 'header'); $this->item->initialize('header'); $this->assertEquals('root', $this->item->getParentId()); }
/** * @param string|null $rootId * * @return BlockView */ protected function getLayoutView($rootId = null) { $this->layoutManipulator->applyChanges($this->context, true); $rawLayout = $this->rawLayoutBuilder->getRawLayout(); return $this->blockFactory->createBlockView($rawLayout, $this->context, $rootId); }