/** * Get configuration per file * * @return array */ public function getConfiguration() { $files = $this->_fileManager->getFileList($this->_basePath . DIRECTORY_SEPARATOR . Tools_Migration_System_Configuration_Reader::SYSTEM_CONFIG_PATH_PATTERN); $result = array(); foreach ($files as $fileName) { $result[$fileName] = $this->_mapper->transform($this->_parser->parse($this->_getDOMDocument($this->_fileManager->getContents($fileName)))); } return $result; }
public function testGetContents() { $this->_readerMock->expects($this->once())->method('getContents')->with('someFile')->will($this->returnValue('123')); $this->assertEquals('123', $this->_model->getContents('someFile')); }