blob: 3b4906fae4e18bd3a0038fc264e4cd36568f2798 [file] [log] [blame]
<!DOCTYPE html>
<script src="../../resources/js-test.js"></script>
<div id="a">
<div id="b">
</div>
</div>
<div id="c">
</div>
<script>
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.dumpChildFramesAsText();
testRunner.waitUntilDone();
}
var frame = document.createElement('iframe');
var a = document.getElementById('a');
var b = document.getElementById('b');
var c = document.getElementById('c');
onload = function() {
b.appendChild(frame);
frame.onload = function() {
frame.contentDocument.body.innerHTML = 'Should be visible.';
};
frame.contentWindow.onunload = function() {
b.parentNode.removeChild(b);
shouldBeNull('frame.contentDocument');
c.appendChild(b);
shouldNotBe('frame.contentDocument', 'null');
isSuccessfullyParsed();
if (window.testRunner)
testRunner.notifyDone();
};
a.parentNode.removeChild(a);
};
</script>