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

Unified Diff: LayoutTests/media/video-durationchange-on-ended.html

Issue 790153002: Add test to verify durationchange event if the actual duration is wrong (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years 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: LayoutTests/media/video-durationchange-on-ended.html
diff --git a/LayoutTests/media/video-durationchange-on-ended.html b/LayoutTests/media/video-durationchange-on-ended.html
new file mode 100644
index 0000000000000000000000000000000000000000..6640ee6ba32987ac81fb1b8f2bb0d6ef1cf52794
--- /dev/null
+++ b/LayoutTests/media/video-durationchange-on-ended.html
@@ -0,0 +1,23 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <script src=media-file.js></script>
philipj_slow 2014/12/10 14:42:13 media-file.js probably isn't needed.
Srirama 2014/12/10 14:45:21 Acknowledged.
+ <script src=video-test.js></script>
+ <script>
+ function onWindowLoad(e)
+ {
+ video = document.getElementById('video');
philipj_slow 2014/12/10 14:42:13 You can simplify the test a bit by moving this scr
Srirama 2014/12/10 14:45:20 I have followed the html structure and put all the
philipj_slow 2014/12/10 15:05:41 It's valid to have scripts in body, and in this ca
+ video.src = "content/truncated.webm";
+ video.play();
+ }
+
+ window.addEventListener('load', onWindowLoad, false);
+ waitForEvent('durationchange');
+ waitForEventAndEnd('ended');
+ </script>
+ </head>
+ <body>
+ <video id="video"></video>
+ <p>Verify there is a 'durationchange' event just before 'ended' event if the initially reported duration exceeds the actual data.</p>
+ </body>
+</html>
« no previous file with comments | « LayoutTests/media/content/truncated.webm ('k') | LayoutTests/media/video-durationchange-on-ended-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698