blob: 3207adbd8c891903b1c6edd65edc41de9b9e7312 [file] [log] [blame]
<!DOCTYPE html>
<link rel="author" title="Robert Flack" href="mailto:flackr@chromium.org">
<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=1209098">
<!-- No crash should occur if a keypress is dispatched to a constructed document. -->
<script>
var newDoc = document.implementation.createDocument( "", null);
var testNode = newDoc.createElement('div');
newDoc.append(testNode);
var syntheticEvent = document.createEvent('KeyboardEvents');
syntheticEvent.initKeyboardEvent("keypress");
testNode.dispatchEvent(syntheticEvent)
</script>