• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1description('Tests that document.createEvent() works with DeviceOrientationEvent.');
2
3var event = document.createEvent('DeviceOrientationEvent');
4
5shouldBeTrue("typeof event == 'object'");
6
7shouldBeTrue("'type' in event");
8shouldBeTrue("'bubbles' in event");
9shouldBeTrue("'cancelable' in event");
10shouldBeTrue("'alpha' in event");
11shouldBeTrue("'beta' in event");
12shouldBeTrue("'gamma' in event");
13
14shouldBeTrue("typeof event.type == 'string'");
15shouldBeTrue("typeof event.bubbles == 'boolean'");
16shouldBeTrue("typeof event.cancelable == 'boolean'");
17shouldBeTrue("typeof event.alpha == 'object'");
18shouldBeTrue("typeof event.beta == 'object'");
19shouldBeTrue("typeof event.gamma == 'object'");
20
21window.successfullyParsed = true;
22