Пример #1
0
 public function testExecute()
 {
     $content = 'test';
     $this->converter->expects($this->once())->method('getXmlFile')->willReturn($content);
     $this->fileFactory->expects($this->once())->method('create')->with('export.xml', $content, 'var')->willReturn($content);
     $this->assertEquals($content, $this->controller->execute());
 }
Пример #2
0
 /**
  * {@inheritdoc}
  */
 public function dispatch(\Magento\Framework\App\RequestInterface $request)
 {
     $pluginInfo = $this->pluginList->getNext($this->subjectType, 'dispatch');
     if (!$pluginInfo) {
         return parent::dispatch($request);
     } else {
         return $this->___callPlugins('dispatch', func_get_args(), $pluginInfo);
     }
 }