| <script src=media-file.js></script> |
| <script src=video-test.js></script> |
| run('video.src = findMediaFile("audio", "content/silence")'); |
| waitForEvent("loadstart"); |
| waitForEvent("ratechange"); |
| waitForEvent("ratechange"); |
| waitForEvent("durationchange"); |
| waitForEvent("loadedmetadata"); |
| waitForEvent("loadeddata"); |
| waitForEvent("canplaythrough"); |
| waitForEvent("timeupdate"); |
| waitForEvent('pause', function () { testExpected("video.paused", true); endTest(); } ); |
| run("handlePromise(video.play())"); |
| <body onload="runTest()"> |
| <p>Test that calling play() and pause() on a video element with audio source triggers play and pause events.</p> |