2017-07-29 00:25:49 +00:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<title>video-create-with-user-gesture</title>
|
|
|
|
<script src=media-file.js></script>
|
|
|
|
<script src=video-test.js></script>
|
|
|
|
<script>
|
|
|
|
function runTest() {
|
|
|
|
run('window.internals.settings.setVideoPlaybackRequiresUserGesture(true);');
|
|
|
|
runWithKeyDown(() => {
|
|
|
|
run('video = document.createElement("video")');
|
|
|
|
});
|
2020-06-03 01:38:28 +00:00
|
|
|
waitForEventAndEnd('playing');
|
2017-07-29 00:25:49 +00:00
|
|
|
run('video.src = findMediaFile("video", "content/test")');
|
|
|
|
run('video.setAttribute("autoplay", "")');
|
|
|
|
run('document.body.appendChild(video)');
|
|
|
|
failTestIn(10000);
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
</head>
|
|
|
|
<body onload="runTest()">
|
|
|
|
</body>
|
|
|
|
</html>
|