Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: third_party/WebKit/LayoutTests/fast/dom/DeviceOrientation/create-event.html

Issue 1737443002: Make DeviceOrientationEvent.prototype.absolute non-nullable (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address feedback Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <body> 3 <body>
4 <script src="../../../resources/js-test.js"></script> 4 <script src="../../../resources/js-test.js"></script>
5 <script> 5 <script>
6 description('Tests that document.createEvent() works with DeviceOrientationEvent .'); 6 description('Tests that document.createEvent() works with DeviceOrientationEvent .');
7 7
8 var event = document.createEvent('DeviceOrientationEvent'); 8 var event = document.createEvent('DeviceOrientationEvent');
9 var newEvent = new CustomEvent("deviceorientation", { 9 var newEvent = new CustomEvent("deviceorientation", {
10 bubbles: false, cancelable: false, 10 bubbles: false, cancelable: false,
(...skipping 13 matching lines...) Expand all
24 shouldBeTrue("'beta' in event"); 24 shouldBeTrue("'beta' in event");
25 shouldBeTrue("'gamma' in event"); 25 shouldBeTrue("'gamma' in event");
26 shouldBeTrue("'absolute' in event"); 26 shouldBeTrue("'absolute' in event");
27 27
28 shouldBeTrue("typeof event.type == 'string'"); 28 shouldBeTrue("typeof event.type == 'string'");
29 shouldBeTrue("typeof event.bubbles == 'boolean'"); 29 shouldBeTrue("typeof event.bubbles == 'boolean'");
30 shouldBeTrue("typeof event.cancelable == 'boolean'"); 30 shouldBeTrue("typeof event.cancelable == 'boolean'");
31 shouldBeTrue("typeof event.alpha == 'object'"); 31 shouldBeTrue("typeof event.alpha == 'object'");
32 shouldBeTrue("typeof event.beta == 'object'"); 32 shouldBeTrue("typeof event.beta == 'object'");
33 shouldBeTrue("typeof event.gamma == 'object'"); 33 shouldBeTrue("typeof event.gamma == 'object'");
34 shouldBeTrue("typeof event.absolute == 'object'"); 34 shouldBeTrue("typeof event.absolute == 'boolean'");
35 35
36 shouldBeEqualToString("newEvent.type", "deviceorientation"); 36 shouldBeEqualToString("newEvent.type", "deviceorientation");
37 shouldBeFalse("newEvent.bubbles"); 37 shouldBeFalse("newEvent.bubbles");
38 shouldBeFalse("newEvent.cancelable"); 38 shouldBeFalse("newEvent.cancelable");
39 39
40 </script> 40 </script>
41 </body> 41 </body>
42 </html> 42 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698