Beispiel #1
0
 /**
  * @param \Magento\Framework\App\Router\ActionList $actionList
  * @param \Magento\Framework\App\ActionFactory $actionFactory
  * @param \Magento\Framework\App\DefaultPathInterface $defaultPath
  * @param \Magento\Framework\App\ResponseFactory $responseFactory
  * @param \Magento\Framework\App\Route\ConfigInterface $routeConfig
  * @param \Magento\Framework\UrlInterface $url
  * @param string $routerId
  * @param \Magento\Framework\Code\NameBuilder $nameBuilder
  * @param \Magento\Framework\App\Router\PathConfigInterface $pathConfig
  * @param \Magento\Framework\App\Config\ScopeConfigInterface $coreConfig
  * @param \Magento\Backend\App\ConfigInterface $backendConfig
  *
  * @SuppressWarnings(PHPMD.ExcessiveParameterList)
  */
 public function __construct(\Magento\Framework\App\Router\ActionList $actionList, \Magento\Framework\App\ActionFactory $actionFactory, \Magento\Framework\App\DefaultPathInterface $defaultPath, \Magento\Framework\App\ResponseFactory $responseFactory, \Magento\Framework\App\Route\ConfigInterface $routeConfig, \Magento\Framework\UrlInterface $url, $routerId, \Magento\Framework\Code\NameBuilder $nameBuilder, \Magento\Framework\App\Router\PathConfigInterface $pathConfig, \Magento\Framework\App\Config\ScopeConfigInterface $coreConfig, \Magento\Backend\App\ConfigInterface $backendConfig)
 {
     parent::__construct($actionList, $actionFactory, $defaultPath, $responseFactory, $routeConfig, $url, $routerId, $nameBuilder, $pathConfig);
     $this->_coreConfig = $coreConfig;
     $this->_backendConfig = $backendConfig;
     $this->_url = $url;
 }
Beispiel #2
0
 /**
  * @param \Magento\Framework\App\Router\ActionList $actionList
  * @param \Magento\Framework\App\ActionFactory $actionFactory
  * @param \Magento\Framework\App\DefaultPathInterface $defaultPath
  * @param \Magento\Framework\App\ResponseFactory $responseFactory
  * @param \Magento\Framework\App\Route\Config $routeConfig
  * @param \Magento\Framework\UrlInterface $url
  * @param string $routerId
  * @param \Magento\Framework\Code\NameBuilder $nameBuilder
  * @param \Magento\Framework\App\Router\PathConfigInterface $pathConfig
  * @param \Magento\Framework\App\RouterListInterface $routerList
  * @param \Magento\DesignEditor\Helper\Data $designEditorHelper
  * @param \Magento\DesignEditor\Model\State $designEditorState
  * @param \Magento\Backend\Model\Auth\Session $session
  *
  * @SuppressWarnings(PHPMD.ExcessiveParameterList)
  */
 public function __construct(\Magento\Framework\App\Router\ActionList $actionList, \Magento\Framework\App\ActionFactory $actionFactory, \Magento\Framework\App\DefaultPathInterface $defaultPath, \Magento\Framework\App\ResponseFactory $responseFactory, \Magento\Framework\App\Route\Config $routeConfig, \Magento\Framework\UrlInterface $url, $routerId, \Magento\Framework\Code\NameBuilder $nameBuilder, \Magento\Framework\App\Router\PathConfigInterface $pathConfig, \Magento\Framework\App\RouterListInterface $routerList, \Magento\DesignEditor\Helper\Data $designEditorHelper, \Magento\DesignEditor\Model\State $designEditorState, \Magento\Backend\Model\Auth\Session $session)
 {
     parent::__construct($actionList, $actionFactory, $defaultPath, $responseFactory, $routeConfig, $url, $routerId, $nameBuilder, $pathConfig);
     $this->_routerList = $routerList;
     $this->_designEditorHelper = $designEditorHelper;
     $this->_state = $designEditorState;
     $this->_session = $session;
 }
Beispiel #3
0
 public function testGetActionClassName()
 {
     $className = 'name of class';
     $module = 'module';
     $prefix = 'Controller';
     $actionPath = 'action path';
     $this->nameBuilderMock->expects($this->once())->method('buildClassName')->with([$module, $prefix, $actionPath])->willReturn($className);
     $this->assertEquals($className, $this->model->getActionClassName($module, $actionPath));
 }
Beispiel #4
0
 public function testGetControllerClassName()
 {
     $this->assertEquals('Magento\\Framework\\Controller\\Index', $this->_model->getActionClassName('Magento_Framework', 'index'));
 }