| <html> |
| <script> |
| function runTest() { |
| if (window.testRunner) |
| testRunner.dumpAsText(); |
| |
| var name = 'touchstart'; |
| var handler = function(){ |
| document.removeEventListener(name, handler, true); |
| }; |
| |
| try { |
| document.addEventListener(name, handler, true); |
| var event = document.createEvent('TouchEvent'); |
| event.initTouchEvent(name); |
| document.dispatchEvent(event); |
| } |
| catch(e){ } |
| |
| document.getElementById("console").innerHTML = "PASSED"; |
| } |
| </script> |
| <body onload="runTest()"> |
| <p>Should not crash when trying to dispath touchEvent without touchList properties</p> |
| <div id="console"></div> |
| </body> |
| </html> |