blob: 57f464a84b8d042a7149b183d71a0fb2b9c935d4 [file] [log] [blame]
<video controls></video>
<script src=media-file.js></script>
<script src=video-test.js></script>
<script>
waitForEvent('canplaythrough',
function () {
testException("video.currentTime = -Infinity", '"TypeError: Failed to set the \'currentTime\' property on \'HTMLMediaElement\': The provided double value is non-finite."');
testException("video.currentTime = Infinity", '"TypeError: Failed to set the \'currentTime\' property on \'HTMLMediaElement\': The provided double value is non-finite."');
testException("video.currentTime = NaN", '"TypeError: Failed to set the \'currentTime\' property on \'HTMLMediaElement\': The provided double value is non-finite."');
video.currentTime = 1.5;
testExpected("video.currentTime.toFixed(1)", 1.5);
video.play();
video.currentTime = 3.1;
testExpected("video.currentTime.toFixed(1)", 3.1);
endTest();
});
video.src = findMediaFile("video", "content/test");
</script>
OSZAR »