blob: 1092e60e60eb7e23bbe3088f5b755ced28b04a1b [file] [log] [blame]
<p>This test verifies that a node does not retain keyboard focus after it has
been removed from the DOM.</p>
<hr>
<input type="text">
<pre id="console">PASS: did not get keyboard event.</pre>
<script>
if (window.layoutTestController)
layoutTestController.dumpAsText();
input = document.getElementsByTagName('input')[0];
input.focus();
input.onkeypress = function() {
document.getElementById('console').innerHTML = "FAIL: got keyboard event.\n"
}
input.parentNode.removeChild(input);
if (window.eventSender)
eventSender.keyDown("A");
else
document.getElementById('console').innerHTML = "This test only runs from DumpRenderTree.\n"
</script>