blob: 81ffbdbc6e31bfc7a8f2f6ca37eb8c6c08181da8 [file] [log] [blame]
<video src=content/test.mp4 playcount=2 controls></video>
<p>Test that video loops when time reaches the value specified by the loopEnd DOM attribute.</p>
<script src=video-test.js></script>
<script>
video.loopEnd=0.5;
test("video.loopEnd==0.5");
test("video.getAttribute('loopend') == '0.5s'");
setTimeout(function () { test("video.currentTime<=0.5"); }, 2000);
waitForEvent('timeupdate', function () {
if (video.currentLoop == 1) {
test("video.currentLoop == 1");
test("video.currentTime.toFixed(1) == 0");
endTest();
}
});
run("video.play()");
</script>