Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(329)

Unified Diff: third_party/WebKit/LayoutTests/media/video-plays-past-end-of-test.html

Issue 2099083002: Convert video-pause* and video-plays* tests to testharness.js (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/media/video-plays-past-end-of-test.html
diff --git a/third_party/WebKit/LayoutTests/media/video-plays-past-end-of-test.html b/third_party/WebKit/LayoutTests/media/video-plays-past-end-of-test.html
index 3a8656c2c0126d81d8620348bdc66628480142c7..a8d2b5a5a16cfb8cb8e3b13bd695a998f023b7a4 100644
--- a/third_party/WebKit/LayoutTests/media/video-plays-past-end-of-test.html
+++ b/third_party/WebKit/LayoutTests/media/video-plays-past-end-of-test.html
@@ -1,14 +1,13 @@
-<p>This test intentionally lets the video keep playing past endTest() to ensure
+<!DOCTYPE html>
+<p>This test intentionally lets the video keep playing past end of test to ensure
that shutdown is clean, since DumpRenderTree used to crash in this case.</p>
-
-<video autoplay id="video"></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>
-<script type="text/javascript">
-if (window.testRunner)
- testRunner.dumpAsText();
-waitForEvent("playing", null, true);
+<video autoplay></video>
+<script src="media-file.js"></script>
+<script>
+testRunner.dumpAsText();
+var video = document.querySelector("video");
+video.onplaying = function() {
+ testRunner.notifyDone();
+};
video.src = findMediaFile("video", "content/test");
-</script>
+</script>

Powered by Google App Engine
This is Rietveld 408576698