graouts@webkit.org | 0d180e7 | 2017-01-20 12:17:50 +0000 | [diff] [blame] | 1 | <!-- webkit-test-runner [ enableModernMediaControls=false ] --> |
dino@apple.com | 3260f52 | 2014-12-03 10:09:06 +0000 | [diff] [blame] | 2 | <html> |
| 3 | <head> |
| 4 | <title>Test that an audio file in a video element should not have a fullscreen button</title> |
| 5 | <script src=media-file.js></script> |
| 6 | <script src=media-controls.js></script> |
| 7 | <script src=video-test.js></script> |
| 8 | <script> |
| 9 | var video; |
| 10 | var panel; |
| 11 | var fullscreenButton; |
| 12 | |
| 13 | function init() |
| 14 | { |
| 15 | video = document.querySelector("video"); |
| 16 | |
| 17 | consoleWrite(""); |
| 18 | consoleWrite("** Playing the video **"); |
| 19 | run("video.play()"); |
| 20 | } |
| 21 | |
| 22 | function test() |
| 23 | { |
| 24 | consoleWrite("** Testing if the fullscreen button is hidden **"); |
| 25 | if (window.internals) { |
| 26 | fullscreenButton = mediaControlsElement(internals.shadowRoot(video).firstChild, "-webkit-media-controls-fullscreen-button"); |
| 27 | testExpected("fullscreenButton.classList.contains('hidden')", true); |
| 28 | testRunner.notifyDone(); |
| 29 | } |
| 30 | } |
| 31 | |
| 32 | </script> |
| 33 | </head> |
| 34 | <body onload="init()"> |
| 35 | Tests that an audio file in a video element should not have a fullscreen button<br> |
| 36 | <video src="content/silence.wav" onplay="test()" controls></video> |
| 37 | </body> |
| 38 | </html> |