| Index: third_party/WebKit/LayoutTests/media/video-dom-autoplay.html
|
| diff --git a/third_party/WebKit/LayoutTests/media/video-dom-autoplay.html b/third_party/WebKit/LayoutTests/media/video-dom-autoplay.html
|
| index 1f52077d70bdeac2131e5cc8b6ebe06458f4f986..8aaf56e22d5f403f4d27cdb792554220e19009a3 100644
|
| --- a/third_party/WebKit/LayoutTests/media/video-dom-autoplay.html
|
| +++ b/third_party/WebKit/LayoutTests/media/video-dom-autoplay.html
|
| @@ -1,17 +1,21 @@
|
| -<video controls></video>
|
| -<script src=media-file.js></script>
|
| -<!-- TODO(foolip): Convert test to testharness.js. crbug.com/588956
|
| - (Please avoid writing new tests using video-test.js) -->
|
| -<script src=video-test.js></script>
|
| +<!DOCTYPE html>
|
| +<title>Test media "autoplay" attribute set via DOM.</title>
|
| +<script src="../resources/testharness.js"></script>
|
| +<script src="../resources/testharnessreport.js"></script>
|
| +<script src="media-file.js"></script>
|
| +<video></video>
|
| <script>
|
| - testExpected("video.autoplay", false);
|
| +async_test(function(t) {
|
| + var video = document.querySelector("video");
|
| + assert_false(video.autoplay);
|
| video.autoplay = true;
|
| - testExpected("video.autoplay", true);
|
| - testExpected("video.getAttribute('autoplay')", null, "!=");
|
| - waitForEvent('play', function () {
|
| - testExpected("video.paused", false);
|
| - endTest();
|
| - } );
|
| + 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>
|
| +});
|
| +</script>
|
|
|