| <html> |
| <head> |
| <script src="../resources/js-test-pre.js"></script> |
| </head> |
| <body> |
| <script> |
| description('Tests that document.createEvent() works with DeviceProximityEvent.'); |
| |
| var event = document.createEvent('DeviceProximityEvent'); |
| |
| shouldBeTrue("typeof event == 'object'"); |
| |
| shouldBeTrue("'type' in event"); |
| shouldBeTrue("'bubbles' in event"); |
| shouldBeTrue("'cancelable' in event"); |
| shouldBeTrue("'value' in event"); |
| shouldBeTrue("'min' in event"); |
| shouldBeTrue("'max' in event"); |
| |
| shouldBeTrue("typeof event.type == 'string'"); |
| shouldBeTrue("typeof event.bubbles == 'boolean'"); |
| shouldBeTrue("typeof event.cancelable == 'boolean'"); |
| shouldBeTrue("typeof event.value == 'number'"); |
| shouldBeTrue("typeof event.min == 'number'"); |
| shouldBeTrue("typeof event.max == 'number'"); |
| </script> |
| <script src="../resources/js-test-post.js"></script> |
| </body> |
| </html> |