blob: 5d3d8fff05486a26f551dd79d9c25a6941dbda84 [file] [log] [blame]
<!DOCTYPE html>
<title>Verify that "autoplay" attribute on a media element starts playback automatically.</title>
<script src="../resources/testharness.js"></script>
<script src="../resources/testharnessreport.js"></script>
<script src="media-file.js"></script>
<video autoplay></video>
<script>
async_test(function(t) {
var video = document.querySelector("video");
assert_true(video.autoplay);
assert_not_equals(video.getAttribute("autoplay"), null);
video.onplay = t.step_func_done(function () {
assert_false(video.paused);
});
video.src = findMediaFile("video", "content/test");
});
</script>