Chromium Code Reviews| Index: LayoutTests/fast/dom/DeviceLight/create-event.html |
| diff --git a/LayoutTests/fast/dom/DeviceLight/create-event.html b/LayoutTests/fast/dom/DeviceLight/create-event.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..f5e7c231e3b91e5d173f59a329d232e1a6413435 |
| --- /dev/null |
| +++ b/LayoutTests/fast/dom/DeviceLight/create-event.html |
| @@ -0,0 +1,24 @@ |
| +<html> |
|
Inactive
2014/05/06 12:58:08
Missing DOCTYPE
riju_
2014/05/09 12:00:21
Done.
|
| +<head> |
| +<script src="../../../resources/js-test.js"></script> |
| +</head> |
| +<body> |
| +<script> |
| +description("Tests that document.createEvent() works with DeviceLightEvent."); |
| + |
| +var event = document.createEvent('DeviceLightEvent'); |
|
Inactive
2014/05/06 12:58:08
It would be good to test the modern way of creatin
riju_
2014/05/09 12:00:21
Done.
|
| + |
|
Inactive
2014/05/06 12:58:08
shouldBe("event.__proto__", "DeviceLightEvent.prot
riju_
2014/05/09 12:00:21
Done.
|
| +shouldBeTrue("typeof event == 'object'"); |
| + |
| +shouldBeTrue("'type' in event"); |
| +shouldBeTrue("'bubbles' in event"); |
| +shouldBeTrue("'cancelable' in event"); |
| +shouldBeTrue("'value' in event"); |
| + |
| +shouldBeTrue("typeof event.type == 'string'"); |
|
Inactive
2014/05/06 12:58:08
You should also check that type is "devicelight".
riju_
2014/05/09 12:00:21
Done.
|
| +shouldBeTrue("typeof event.bubbles == 'boolean'"); |
|
Inactive
2014/05/06 12:58:08
You should also check that bubbles is true.
riju_
2014/05/09 12:00:21
Done.
|
| +shouldBeTrue("typeof event.cancelable == 'boolean'"); |
|
Inactive
2014/05/06 12:58:08
You should also check that cancelable is false.
riju_
2014/05/09 12:00:21
Done.
|
| +shouldBeTrue("typeof event.value == 'number'"); |
|
Inactive
2014/05/06 12:58:08
You should check the value as well.
riju_
2014/05/09 12:00:21
Done.
|
| +</script> |
| +</body> |
| +</html> |