Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / events / initkeyboardevent-crash.html
blob30a5757689f03a8bcf27137da3e054d3f3586dd7
1 <p>This tests that dispatching a keyboard event created via javascript does
2 not crash.</p>
3 <p id="results"></p>
5 <input id="1">
6 <script>
7 if (window.testRunner)
8 testRunner.dumpAsText();
10 var evt = document.createEvent("KeyboardEvent");
11 evt.initKeyboardEvent("keydown", true, true, window, 0, 0, 0, 0, 0, 0, "a");
12 var elt = document.getElementById("1");
13 elt.focus();
14 elt.dispatchEvent(evt);
16 document.getElementById("results").innerText = "PASSED";
17 </script>