public function testGetFile() { $theme = $this->getMockForAbstractClass('\\Magento\\Framework\\View\\Design\\ThemeInterface'); $expected = 'some/file.ext'; $this->resolver->expects($this->once())->method('resolve')->with(RulePool::TYPE_LOCALE_FILE, 'file.ext', 'frontend', $theme, 'en_US', null)->will($this->returnValue($expected)); $actual = $this->object->getFile('frontend', $theme, 'en_US', 'file.ext'); $this->assertSame($expected, $actual); }
/** * Get a locale file * * @param string $file * @param array $params * @return string */ public function getLocaleFileName($file, array $params = []) { $this->_assetRepo->updateDesignParams($params); return $this->_localeFileResolution->getFile($params['area'], $params['themeModel'], $params['locale'], $file); }