blob: 75971396298b4c3579945356595dd58eb6da208d [file] [log] [blame]
<video controls></video>
<p>Test that seeking paused video past it's duration time sets currentTime to duration and leaves video paused.</p>
<script src=video-test.js></script>
<script>
waitForEvent('load', function () {
// exact amount of timeupdate events is timing and implementation dependent
var first = true;
video.addEventListener("timeupdate", function () {
if (first) {
consoleWrite("EVENT(timeupdate)");
test("video.currentTime == video.duration");
}
else if (video.currentTime != video.duration)
test("video.currentTime == video.duration");
first = false;
});
run("video.currentTime = 500");
endTestLater();
});
video.src = "content/test.mp4";
run("video.load()");
</script>