OLD | NEW |
1 <html> | 1 <html> |
2 <head> | 2 <head> |
3 <title>Test that media autoplay should not work if user gesture is requi
red for playback</title> | 3 <title>Test that media autoplay should not work if user gesture is requi
red for playback</title> |
4 <script src=media-file.js></script> | 4 <script src=media-file.js></script> |
5 <!-- TODO(philipj): Convert test to testharness.js. crbug.com/588956 | 5 <!-- TODO(foolip): Convert test to testharness.js. crbug.com/588956 |
6 (Please avoid writing new tests using video-test.js) --> | 6 (Please avoid writing new tests using video-test.js) --> |
7 <script src=video-test.js></script> | 7 <script src=video-test.js></script> |
8 <script> | 8 <script> |
9 if (window.internals) | 9 if (window.internals) |
10 window.internals.settings.setMediaPlaybackRequiresUserGesture(tr
ue); | 10 window.internals.settings.setMediaPlaybackRequiresUserGesture(tr
ue); |
11 | 11 |
12 function testPlay() | 12 function testPlay() |
13 { | 13 { |
14 failTest("play event should not fire without user gesture."); | 14 failTest("play event should not fire without user gesture."); |
15 } | 15 } |
(...skipping 18 matching lines...) Expand all Loading... |
34 waitForEvent('play', testPlay); | 34 waitForEvent('play', testPlay); |
35 } | 35 } |
36 </script> | 36 </script> |
37 </head> | 37 </head> |
38 | 38 |
39 <body onload="start()"> | 39 <body onload="start()"> |
40 <p>Test that media autoplay should not work if user gesture is required for
playback.</p> | 40 <p>Test that media autoplay should not work if user gesture is required for
playback.</p> |
41 <video controls autoplay></video> | 41 <video controls autoplay></video> |
42 </body> | 42 </body> |
43 </html> | 43 </html> |
OLD | NEW |