Exemple #1
0
 /**
  * @param string $xmlData
  * @dataProvider wrongXmlDataProvider
  * @expectedException \Exception
  * @expectedExceptionMessage Invalid application config. Unknown node: wrong_node.
  */
 public function testMapThrowsExceptionWhenXmlHasWrongFormat($xmlData)
 {
     $dom = new \DOMDocument();
     $dom->loadXML($xmlData);
     $this->_mapper->convert($dom);
 }
 public function testRead()
 {
     $model = new \Magento\Framework\ObjectManager\Config\Reader\Dom($this->_fileResolverMock, $this->_mapper, $this->_schemaLocator, $this->_validationState);
     $this->assertEquals($this->_mapper->convert($this->_mergedConfig), $model->read('scope'));
 }