Пример #1
0
 /**
  * @covers ByJG\Util\XmlUtil::removeNode
  */
 public function testRemoveNode()
 {
     $dom = XmlUtil::createXmlDocumentFromStr('<root><subject>Text</subject><a/><b/></root>');
     $node = XmlUtil::selectSingleNode($dom->documentElement, 'subject');
     XmlUtil::removeNode($node);
     $this->assertEquals(self::XMLHEADER . "\n" . '<root>' . '<a/>' . '<b/>' . '</root>' . "\n", $dom->saveXML());
 }