Index: LayoutTests/fast/events/wheelevent-constructor.html |
diff --git a/LayoutTests/fast/events/wheelevent-constructor.html b/LayoutTests/fast/events/wheelevent-constructor.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..2eb7b1885127c024f5dc0262c7cf3eb29e609024 |
--- /dev/null |
+++ b/LayoutTests/fast/events/wheelevent-constructor.html |
@@ -0,0 +1,29 @@ |
+<!DOCTYPE html> |
+<html> |
+<head> |
+<link rel="help" href="http://www.w3.org/TR/DOM-Level-3-Events/#events-WheelEvent"> |
+<script src="../js/resources/js-test-pre.js"></script> |
+</head> |
+<body> |
+<script> |
+description("Tests the constructor of the standard wheel event"); |
+ |
+var testEvent; |
+shouldNotThrow("testEvent = new WheelEvent('wheel')"); |
+shouldBe("testEvent.__proto__", "WheelEvent.prototype"); |
+shouldBe("testEvent.deltaX", "0"); |
+shouldBe("testEvent.deltaY", "0"); |
+shouldBe("testEvent.deltaZ", "0"); |
+shouldBe("testEvent.deltaMode", "WheelEvent.DOM_DELTA_PIXEL"); |
+ |
+shouldNotThrow("testEvent = new WheelEvent('wheel', { deltaX: 10.2, deltaY: 20.3, deltaZ: 30.4, deltaMode: WheelEvent.DOM_DELTA_PAGE })"); |
+shouldBe("testEvent.__proto__", "WheelEvent.prototype"); |
+shouldBe("testEvent.deltaX", "10.2"); |
+shouldBe("testEvent.deltaY", "20.3"); |
+shouldBe("testEvent.deltaZ", "30.4"); |
+shouldBe("testEvent.deltaMode", "WheelEvent.DOM_DELTA_PAGE"); |
+ |
+</script> |
+<script src="../js/resources/js-test-post.js"></script> |
+</body> |
+</html> |