blob: c87cfea521db74d75f855f4c77935dad601c377f [file] [log] [blame]
<p><a href="rdar://problem/6621701">rdar://problem/6621701</a> Test that XML resources with incorrect encoding retrieved via XMLHttpRequest are fully decoded,
cf. <a href="https://bugs.webkit.org/show_bug.cgi?id=17079">bug 17079</a>.</p>
<script>
if (window.testRunner)
testRunner.dumpAsText();
var req = new XMLHttpRequest;
req.open("GET", "resources/broken-encoding.xml", false);
req.overrideMimeType('text/xml');
req.setRequestHeader("Cache-Control", "no-cache");
req.send(null);
document.write((req.responseXML.documentElement.firstChild.length == 6) ? "PASS" : "FAIL");
</script>