9 const WELL_FORMED_XML =
"<root><child /></root>";
10 const MAL_FORMED_XML =
"<root><child /></error>";
11 const XML_WITH_PIH =
'<?xml version="1.0"?><?xml-stylesheet type="text/xsl" href="/w/index.php"?><svg><child /></svg>';
17 public function testWellFormedXML() {
19 $this->assertTrue( $testXML->wellFormed );
20 $this->assertEquals(
'root', $testXML->getRootElement() );
26 public function testMalFormedXML() {
28 $this->assertFalse( $testXML->wellFormed );
34 public function testProcessingInstructionHandler() {
41 'processing_instruction_handler' =>
function() use ( &$called ) {
46 $this->assertTrue( $called );