1--TEST-- 2XMLReader: Bug #70309 XmlReader read generates extra output 3--SKIPIF-- 4<?php if (substr(PHP_OS, 0, 3) != 'WIN') die('skip.. only for Windows'); ?> 5<?php if (!extension_loaded("xmlreader")) print "skip"; ?> 6<?php if (getenv("SKIP_SLOW_TESTS")) die("skip slow test"); ?> 7<?php if (getenv("SKIP_ONLINE_TESTS")) die("skip online test"); ?> 8--FILE-- 9<?php 10 11/* From the bug report an extra message comes from libxml2 debug output left unwrapped. */ 12 13$doc = new \XMLReader(); 14 15$doc->xml('<?xml version="1.0" encoding="UTF-8"?> 16<chapter xmlns="http://docbook.org/ns/docbook" version="5.0"> 17<title>Test Chapter</title> 18<para> 19This is a paragraph in the test chapter. It is unremarkable in 20every regard. This is a paragraph in the test chapter. It is 21unremarkable in every regard. This is a paragraph in the test 22chapter. It is unremarkable in every regard. 23</para> 24<paar> 25<emphasis role="bold">This</emphasis> paragraph contains 26<emphasis>some <emphasis>emphasized</emphasis> text</emphasis> 271and a <superscript>super</superscript>script 28and a <subscript>sub</subscript>script. 29</para> 30<para> 31This is a paragraph in the test chapter. It is unremarkable in 32every regard. This is a paragraph in the test chapter. It is 33unremarkable in every regard. This is a paragraph in the test 34chapter. It is unremarkable in every regard. 35</para> 36</chapter>'); 37 38$doc->setRelaxNGSchema('http://docs.oasis-open.org/docbook/rng/5.0/docbook.rng'); 39 40while (@$doc->read() !== false); 41?> 42===DONE=== 43--EXPECT-- 44===DONE=== 45