Index: LayoutTests/fast/events/drag-extra-mouse-down-no-crash.html |
diff --git a/LayoutTests/fast/events/drag-extra-mouse-down-no-crash.html b/LayoutTests/fast/events/drag-extra-mouse-down-no-crash.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..7460d7e9d7c353b3bd2199cd1d590c80ea461871 |
--- /dev/null |
+++ b/LayoutTests/fast/events/drag-extra-mouse-down-no-crash.html |
@@ -0,0 +1,27 @@ |
+<!DOCTYPE html> |
+<p> |
+Ill-formed uses of eventSender.mouseDown() while drag is under way should not crash. |
+</p> |
+<script> |
+if (window.testRunner) { |
+ testRunner.dumpAsText(); |
+ testRunner.waitUntilDone(); |
+} |
+ |
+function runTest() { |
+ if (!window.eventSender) |
+ return; |
+ |
+ eventSender.beginDragWithFiles([""]); |
+ var x = document.getElementById("link").offsetLeft; |
+ var y = document.getElementById("link").offsetTop; |
+ eventSender.mouseMoveTo(x, y); |
+ eventSender.mouseDown(); |
+ eventSender.mouseMoveTo(x, y + 1); |
+ eventSender.mouseUp(); |
+ testRunner.notifyDone(); |
+} |
+ |
+window.onload = runTest; |
+</script> |
+<a href="data:text/html," id="link">PASS(no crash)</a> |