 Chromium Code Reviews
 Chromium Code Reviews Issue 775763007:
  Use event init dictionary in modules/device_light  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/blink.git@master
    
  
    Issue 775763007:
  Use event init dictionary in modules/device_light  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/blink.git@master| OLD | NEW | 
|---|---|
| 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 DeviceLightEvent."); | 6 description("Tests that document.createEvent() works with DeviceLightEvent."); | 
| 7 | 7 | 
| 8 var event = document.createEvent('DeviceLightEvent'); | 8 var event = document.createEvent('DeviceLightEvent'); | 
| 9 var newEvent = new DeviceLightEvent("devicelight", { | 9 var newEvent = new DeviceLightEvent("devicelight", { | 
| 10 bubbles: true, cancelable: false, | 10 bubbles: true, cancelable: false, | 
| (...skipping 13 matching lines...) Expand all Loading... | |
| 24 | 24 | 
| 25 shouldBeTrue("typeof newEvent.type == 'string'"); | 25 shouldBeTrue("typeof newEvent.type == 'string'"); | 
| 26 shouldBeEqualToString("newEvent.type", "devicelight"); | 26 shouldBeEqualToString("newEvent.type", "devicelight"); | 
| 27 shouldBeTrue("typeof newEvent.bubbles == 'boolean'"); | 27 shouldBeTrue("typeof newEvent.bubbles == 'boolean'"); | 
| 28 shouldBeTrue("newEvent.bubbles"); | 28 shouldBeTrue("newEvent.bubbles"); | 
| 29 shouldBeTrue("typeof newEvent.cancelable == 'boolean'"); | 29 shouldBeTrue("typeof newEvent.cancelable == 'boolean'"); | 
| 30 shouldBeFalse("newEvent.cancelable") | 30 shouldBeFalse("newEvent.cancelable") | 
| 31 shouldBeTrue("typeof newEvent.value == 'number'"); | 31 shouldBeTrue("typeof newEvent.value == 'number'"); | 
| 32 shouldBeEqualToNumber('newEvent.value', 10); | 32 shouldBeEqualToNumber('newEvent.value', 10); | 
| 33 | 33 | 
| 34 shouldBeTrue("defaultEvent.bubbles"); | 34 shouldBeFalse("defaultEvent.bubbles"); | 
| 
timvolodine
2014/12/03 12:37:50
unless I am missing something the spec explicitly
 
bashi
2014/12/04 23:40:52
It seems that I forgot to put a comment to describ
 
timvolodine
2014/12/09 14:49:29
I did not write the spec :/, I was looking at http
 
bashi
2014/12/10 00:06:06
Hmm, my point was "a user agent" is different from
 | |
| 35 shouldBeFalse("defaultEvent.cancelable"); | 35 shouldBeFalse("defaultEvent.cancelable"); | 
| 36 </script> | 36 </script> | 
| 37 </body> | 37 </body> | 
| 38 </html> | 38 </html> | 
| OLD | NEW |