blob: eae05b4cc8e860f2eb8c4d5c4cb07e03001aaa05 [file] [log] [blame]
Tests for moving the focus onto controls inside an audio element and a video element.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS document.body.focus(); eventSender.keyDown("\t"); document.activeElement is mediaElements[0]
PASS mediaElements[0] instanceof HTMLAudioElement is true
PASS mediaElements[0].controls is true
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[0]
PASS !!internals.shadowRoot(mediaElements[0]).activeElement /* play button */ is true
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[0]
PASS !!internals.shadowRoot(mediaElements[0]).activeElement /* rewind button */ is true
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[0]
PASS !!internals.shadowRoot(mediaElements[0]).activeElement /* volume slider */ is true
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[0]
PASS !!internals.shadowRoot(mediaElements[0]).activeElement /* mute button */ is true
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[1]
PASS mediaElements[1] instanceof HTMLVideoElement is true
PASS mediaElements[1].controls is true
FAIL !!internals.shadowRoot(mediaElements[1]).activeElement /* play button */ should be true. Was false.
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[1]
PASS !!internals.shadowRoot(mediaElements[1]).activeElement /* rewind button */ is true
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[1]
PASS !!internals.shadowRoot(mediaElements[1]).activeElement /* volume slider */ is true
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[1]
PASS !!internals.shadowRoot(mediaElements[1]).activeElement /* mute button */ is true
FAIL eventSender.keyDown("\t"); document.activeElement should be [object HTMLAudioElement]. Was [object HTMLVideoElement].
PASS mediaElements[2] instanceof HTMLAudioElement is true
PASS mediaElements[2].controls is false
PASS eventSender.keyDown("\t"); document.activeElement is mediaElements[3]
PASS mediaElements[3] instanceof HTMLVideoElement is true
PASS mediaElements[3].controls is false
PASS eventSender.keyDown("\t"); document.activeElement is document.querySelector("div")
PASS successfullyParsed is true
TEST COMPLETE