blob: dbe266b2930a67b7e6af7f0386327d0d74a8f8d6 [file] [log] [blame]
<!DOCTYPE html>
<title>moving modified IFRAME in document (original page about:blank, document.write modification)</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<link rel="help" href="https://html.spec.whatwg.org/#iframe-load-event-steps">
<iframe src="about:blank"></iframe>
<div id="target"></div>
<script>
onload = function() {
var ifr = document.getElementsByTagName('iframe')[0];
ifr.contentDocument.open();
ifr.contentDocument.write('Modified document');
ifr.contentDocument.close();
setTimeout(function() {
ifr.onload = function() {
assert_equals(ifr.contentDocument.body.textContent.indexOf('Modified'), -1);
done();
};
document.getElementById('target').appendChild(ifr);
}, 100);
}
</script>