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

Unified Diff: LayoutTests/media/avtrack/forget-on-load.html

Issue 284513003: Implement AudioTrack, AudioTrackList, VideoTrack, and VideoTrackList (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: nits Created 6 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
« no previous file with comments | « LayoutTests/media/avtrack/audio-track-enabled.html ('k') | LayoutTests/media/avtrack/gc.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/media/avtrack/forget-on-load.html
diff --git a/LayoutTests/media/avtrack/forget-on-load.html b/LayoutTests/media/avtrack/forget-on-load.html
new file mode 100644
index 0000000000000000000000000000000000000000..52657d55368f55f5d796f38bffbbd3fd402dff0d
--- /dev/null
+++ b/LayoutTests/media/avtrack/forget-on-load.html
@@ -0,0 +1,35 @@
+<!doctype html>
+<html>
+ <head>
+ <title>AudioTrackList &amp; VideoTrackList after load()</title>
+ <script src="../../resources/testharness.js"></script>
+ <script src="../../resources/testharnessreport.js"></script>
+ <script src="../media-file.js"></script>
+ </head>
+ <body>
+ <div id="log"></div>
+ <script>
+ async_test(function(t)
+ {
+ var e = document.createElement("video");
+ e.src = findMediaFile("video", "../content/test");
+
+ e.addEventListener("loadedmetadata", t.step_func(function()
+ {
+
+ assert_equals(e.audioTracks.length, 1, "audioTracks.length");
+ assert_equals(e.videoTracks.length, 1, "videoTracks.length");
+ assert_equals(e.videoTracks.selectedIndex, 0, "videoTracks.selectedIndex");
+
+ e.load();
+
+ assert_equals(e.audioTracks.length, 0, "audioTracks.length");
+ assert_equals(e.videoTracks.length, 0, "videoTracks.length");
+ assert_equals(e.videoTracks.selectedIndex, -1, "videoTracks.selectedIndex");
+
+ t.done();
+ }));
+ });
+ </script>
+ </body>
+</html>
« no previous file with comments | « LayoutTests/media/avtrack/audio-track-enabled.html ('k') | LayoutTests/media/avtrack/gc.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698