public function testAddUpdate() { $processor = $this->getMock('Magento\\Framework\\View\\Layout\\ProcessorInterface', [], [], '', false); $processor->expects($this->once())->method('addUpdate')->with('handle_name'); $this->layout->expects($this->once())->method('getUpdate')->will($this->returnValue($processor)); $this->resultLayout->addUpdate('handle_name'); }
/** * {@inheritdoc} */ public function addUpdate($update) { $pluginInfo = $this->pluginList->getNext($this->subjectType, 'addUpdate'); if (!$pluginInfo) { return parent::addUpdate($update); } else { return $this->___callPlugins('addUpdate', func_get_args(), $pluginInfo); } }