OLD | NEW |
1 CONSOLE WARNING: line 1: 'KeyboardEvent.keyIdentifier' is deprecated and will be
removed in M53, around September 2016. See https://www.chromestatus.com/feature
s/5316065118650368 for more details. | |
2 This tests the constructor for the KeyboardEvent DOM class. | 1 This tests the constructor for the KeyboardEvent DOM class. |
3 | 2 |
4 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". |
5 | 4 |
6 | 5 |
7 PASS new KeyboardEvent('eventType').bubbles is false | 6 PASS new KeyboardEvent('eventType').bubbles is false |
8 PASS new KeyboardEvent('eventType').cancelable is false | 7 PASS new KeyboardEvent('eventType').cancelable is false |
9 PASS new KeyboardEvent('eventType').view is null | 8 PASS new KeyboardEvent('eventType').view is null |
10 PASS new KeyboardEvent('eventType').detail is 0 | 9 PASS new KeyboardEvent('eventType').detail is 0 |
11 PASS new KeyboardEvent('eventType').keyIdentifier is "" | |
12 PASS new KeyboardEvent('eventType').location is 0 | 10 PASS new KeyboardEvent('eventType').location is 0 |
13 PASS new KeyboardEvent('eventType').ctrlKey is false | 11 PASS new KeyboardEvent('eventType').ctrlKey is false |
14 PASS new KeyboardEvent('eventType').altKey is false | 12 PASS new KeyboardEvent('eventType').altKey is false |
15 PASS new KeyboardEvent('eventType').shiftKey is false | 13 PASS new KeyboardEvent('eventType').shiftKey is false |
16 PASS new KeyboardEvent('eventType').metaKey is false | 14 PASS new KeyboardEvent('eventType').metaKey is false |
17 PASS new KeyboardEvent('eventType').repeat is false | 15 PASS new KeyboardEvent('eventType').repeat is false |
18 PASS new KeyboardEvent('eventType', { bubbles: false }).bubbles is false | 16 PASS new KeyboardEvent('eventType', { bubbles: false }).bubbles is false |
19 PASS new KeyboardEvent('eventType', { bubbles: true }).bubbles is true | 17 PASS new KeyboardEvent('eventType', { bubbles: true }).bubbles is true |
20 PASS new KeyboardEvent('eventType', { cancelable: false }).cancelable is false | 18 PASS new KeyboardEvent('eventType', { cancelable: false }).cancelable is false |
21 PASS new KeyboardEvent('eventType', { cancelable: true }).cancelable is true | 19 PASS new KeyboardEvent('eventType', { cancelable: true }).cancelable is true |
22 PASS new KeyboardEvent('eventType', { view: window }).view is window | 20 PASS new KeyboardEvent('eventType', { view: window }).view is window |
23 PASS new KeyboardEvent('eventType', { view: this }).view is this | 21 PASS new KeyboardEvent('eventType', { view: this }).view is this |
24 PASS new KeyboardEvent('eventType', { view: testObject }).view threw exception T
ypeError: Failed to construct 'KeyboardEvent': member view is not of type Window
.. | 22 PASS new KeyboardEvent('eventType', { view: testObject }).view threw exception T
ypeError: Failed to construct 'KeyboardEvent': member view is not of type Window
.. |
25 PASS new KeyboardEvent('eventType', { view: document }).view threw exception Typ
eError: Failed to construct 'KeyboardEvent': member view is not of type Window.. | 23 PASS new KeyboardEvent('eventType', { view: document }).view threw exception Typ
eError: Failed to construct 'KeyboardEvent': member view is not of type Window.. |
26 PASS new KeyboardEvent('eventType', { view: undefined }).view is null | 24 PASS new KeyboardEvent('eventType', { view: undefined }).view is null |
27 PASS new KeyboardEvent('eventType', { view: null }).view is null | 25 PASS new KeyboardEvent('eventType', { view: null }).view is null |
28 PASS new KeyboardEvent('eventType', { view: false }).view threw exception TypeEr
ror: Failed to construct 'KeyboardEvent': member view is not of type Window.. | 26 PASS new KeyboardEvent('eventType', { view: false }).view threw exception TypeEr
ror: Failed to construct 'KeyboardEvent': member view is not of type Window.. |
29 PASS new KeyboardEvent('eventType', { view: true }).view threw exception TypeErr
or: Failed to construct 'KeyboardEvent': member view is not of type Window.. | 27 PASS new KeyboardEvent('eventType', { view: true }).view threw exception TypeErr
or: Failed to construct 'KeyboardEvent': member view is not of type Window.. |
30 PASS new KeyboardEvent('eventType', { view: '' }).view threw exception TypeError
: Failed to construct 'KeyboardEvent': member view is not of type Window.. | 28 PASS new KeyboardEvent('eventType', { view: '' }).view threw exception TypeError
: Failed to construct 'KeyboardEvent': member view is not of type Window.. |
31 PASS new KeyboardEvent('eventType', { view: 'chocolate' }).view threw exception
TypeError: Failed to construct 'KeyboardEvent': member view is not of type Windo
w.. | 29 PASS new KeyboardEvent('eventType', { view: 'chocolate' }).view threw exception
TypeError: Failed to construct 'KeyboardEvent': member view is not of type Windo
w.. |
32 PASS new KeyboardEvent('eventType', { view: 12345 }).view threw exception TypeEr
ror: Failed to construct 'KeyboardEvent': member view is not of type Window.. | 30 PASS new KeyboardEvent('eventType', { view: 12345 }).view threw exception TypeEr
ror: Failed to construct 'KeyboardEvent': member view is not of type Window.. |
33 PASS new KeyboardEvent('eventType', { view: 18446744073709551615 }).view threw e
xception TypeError: Failed to construct 'KeyboardEvent': member view is not of t
ype Window.. | 31 PASS new KeyboardEvent('eventType', { view: 18446744073709551615 }).view threw e
xception TypeError: Failed to construct 'KeyboardEvent': member view is not of t
ype Window.. |
34 PASS new KeyboardEvent('eventType', { view: NaN }).view threw exception TypeErro
r: Failed to construct 'KeyboardEvent': member view is not of type Window.. | 32 PASS new KeyboardEvent('eventType', { view: NaN }).view threw exception TypeErro
r: Failed to construct 'KeyboardEvent': member view is not of type Window.. |
35 PASS new KeyboardEvent('eventType', { view: {valueOf: function () { return windo
w; } } }).view == window threw exception TypeError: Failed to construct 'Keyboar
dEvent': member view is not of type Window.. | 33 PASS new KeyboardEvent('eventType', { view: {valueOf: function () { return windo
w; } } }).view == window threw exception TypeError: Failed to construct 'Keyboar
dEvent': member view is not of type Window.. |
36 PASS new KeyboardEvent('eventType', { get view() { return window; } }).view is w
indow | 34 PASS new KeyboardEvent('eventType', { get view() { return window; } }).view is w
indow |
37 PASS new KeyboardEvent('eventType', { get view() { return 123; } }).view threw e
xception TypeError: Failed to construct 'KeyboardEvent': member view is not of t
ype Window.. | 35 PASS new KeyboardEvent('eventType', { get view() { return 123; } }).view threw e
xception TypeError: Failed to construct 'KeyboardEvent': member view is not of t
ype Window.. |
38 PASS new KeyboardEvent('eventType', { get view() { throw 'KeyboardEvent Error';
} }) threw exception KeyboardEvent Error. | 36 PASS new KeyboardEvent('eventType', { get view() { throw 'KeyboardEvent Error';
} }) threw exception KeyboardEvent Error. |
39 PASS new KeyboardEvent('eventType', { keyIdentifier: 'koakuma' }).keyIdentifier
is "koakuma" | |
40 PASS new KeyboardEvent('eventType', { keyIdentifier: '' }).keyIdentifier is "" | |
41 PASS new KeyboardEvent('eventType', { keyIdentifier: undefined }).keyIdentifier
is "" | |
42 PASS new KeyboardEvent('eventType', { keyIdentifier: null }).keyIdentifier is "n
ull" | |
43 PASS new KeyboardEvent('eventType', { keyIdentifier: false }).keyIdentifier is "
false" | |
44 PASS new KeyboardEvent('eventType', { keyIdentifier: true }).keyIdentifier is "t
rue" | |
45 PASS new KeyboardEvent('eventType', { keyIdentifier: 12345 }).keyIdentifier is "
12345" | |
46 PASS new KeyboardEvent('eventType', { keyIdentifier: 18446744073709551615 }).key
Identifier is "18446744073709552000" | |
47 PASS new KeyboardEvent('eventType', { keyIdentifier: NaN }).keyIdentifier is "Na
N" | |
48 PASS new KeyboardEvent('eventType', { keyIdentifier: [] }).keyIdentifier is "" | |
49 PASS new KeyboardEvent('eventType', { keyIdentifier: [1, 2, 3] }).keyIdentifier
is "1,2,3" | |
50 PASS new KeyboardEvent('eventType', { keyIdentifier: {koakuma: 12345} }).keyIden
tifier is "[object Object]" | |
51 PASS new KeyboardEvent('eventType', { keyIdentifier: {valueOf: function () { ret
urn 'koakuma'; } } }).keyIdentifier is "[object Object]" | |
52 PASS new KeyboardEvent('eventType', { code: 'koakuma' }).code is "koakuma" | 37 PASS new KeyboardEvent('eventType', { code: 'koakuma' }).code is "koakuma" |
53 PASS new KeyboardEvent('eventType', { code: '' }).code is "" | 38 PASS new KeyboardEvent('eventType', { code: '' }).code is "" |
54 PASS new KeyboardEvent('eventType', { code: undefined }).code is "" | 39 PASS new KeyboardEvent('eventType', { code: undefined }).code is "" |
55 PASS new KeyboardEvent('eventType', { code: null }).code is "null" | 40 PASS new KeyboardEvent('eventType', { code: null }).code is "null" |
56 PASS new KeyboardEvent('eventType', { code: false }).code is "false" | 41 PASS new KeyboardEvent('eventType', { code: false }).code is "false" |
57 PASS new KeyboardEvent('eventType', { code: true }).code is "true" | 42 PASS new KeyboardEvent('eventType', { code: true }).code is "true" |
58 PASS new KeyboardEvent('eventType', { code: 12345 }).code is "12345" | 43 PASS new KeyboardEvent('eventType', { code: 12345 }).code is "12345" |
59 PASS new KeyboardEvent('eventType', { code: 18446744073709551615 }).code is "184
46744073709552000" | 44 PASS new KeyboardEvent('eventType', { code: 18446744073709551615 }).code is "184
46744073709552000" |
60 PASS new KeyboardEvent('eventType', { code: NaN }).code is "NaN" | 45 PASS new KeyboardEvent('eventType', { code: NaN }).code is "NaN" |
61 PASS new KeyboardEvent('eventType', { code: [] }).code is "" | 46 PASS new KeyboardEvent('eventType', { code: [] }).code is "" |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 PASS new KeyboardEvent('eventType', { modifierFn: false }).getModifierState('Fn'
); is false | 105 PASS new KeyboardEvent('eventType', { modifierFn: false }).getModifierState('Fn'
); is false |
121 PASS new KeyboardEvent('eventType', { modifierFn: true }).getModifierState('Fn')
; is true | 106 PASS new KeyboardEvent('eventType', { modifierFn: true }).getModifierState('Fn')
; is true |
122 PASS new KeyboardEvent('eventType', { modifierCapsLock: false }).getModifierStat
e('CapsLock'); is false | 107 PASS new KeyboardEvent('eventType', { modifierCapsLock: false }).getModifierStat
e('CapsLock'); is false |
123 PASS new KeyboardEvent('eventType', { modifierCapsLock: true }).getModifierState
('CapsLock'); is true | 108 PASS new KeyboardEvent('eventType', { modifierCapsLock: true }).getModifierState
('CapsLock'); is true |
124 PASS new KeyboardEvent('eventType', { modifierScrollLock: false }).getModifierSt
ate('ScrollLock'); is false | 109 PASS new KeyboardEvent('eventType', { modifierScrollLock: false }).getModifierSt
ate('ScrollLock'); is false |
125 PASS new KeyboardEvent('eventType', { modifierScrollLock: true }).getModifierSta
te('ScrollLock'); is true | 110 PASS new KeyboardEvent('eventType', { modifierScrollLock: true }).getModifierSta
te('ScrollLock'); is true |
126 PASS new KeyboardEvent('eventType', { modifierNumLock: false }).getModifierState
('NumLock'); is false | 111 PASS new KeyboardEvent('eventType', { modifierNumLock: false }).getModifierState
('NumLock'); is false |
127 PASS new KeyboardEvent('eventType', { modifierNumLock: true }).getModifierState(
'NumLock'); is true | 112 PASS new KeyboardEvent('eventType', { modifierNumLock: true }).getModifierState(
'NumLock'); is true |
128 PASS new KeyboardEvent('eventType', { modifierSymbol: false }).getModifierState(
'Symbol'); is false | 113 PASS new KeyboardEvent('eventType', { modifierSymbol: false }).getModifierState(
'Symbol'); is false |
129 PASS new KeyboardEvent('eventType', { modifierSymbol: true }).getModifierState('
Symbol'); is true | 114 PASS new KeyboardEvent('eventType', { modifierSymbol: true }).getModifierState('
Symbol'); is true |
130 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).bubbles is true | 115 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).bubbles is true |
131 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).cancelable is true | 116 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).cancelable is true |
132 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).view is window | 117 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).view is window |
133 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).detail is 111 | 118 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).detail is 111 |
134 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).keyIdentifier is "chocolate" | 119 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).code is "chocode" |
135 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).code is "chocode" | 120 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).key is "chokey" |
136 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).key is "chokey" | 121 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).location is 222 |
137 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).location is 222 | 122 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).ctrlKey is true |
138 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).ctrlKey is true | 123 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).altKey is true |
139 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).altKey is true | 124 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).shiftKey is true |
140 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).shiftKey is true | 125 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).metaKey is true |
141 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).metaKey is true | 126 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, code: 'chocode', key: 'chokey', location: 222, ctrlKey: true,
altKey: true, shiftKey: true, metaKey: true, repeat: true }).repeat is true |
142 PASS new KeyboardEvent('eventType', { bubbles: true, cancelable: true, view: win
dow, detail: 111, keyIdentifier: 'chocolate', code: 'chocode', key: 'chokey', lo
cation: 222, ctrlKey: true, altKey: true, shiftKey: true, metaKey: true, repeat:
true }).repeat is true | |
143 PASS successfullyParsed is true | 127 PASS successfullyParsed is true |
144 | 128 |
145 TEST COMPLETE | 129 TEST COMPLETE |
146 | 130 |
OLD | NEW |