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

Side by Side Diff: third_party/WebKit/LayoutTests/media/track/track-cue-rendering-tree-is-removed-properly.html

Issue 2268923003: Clean up textTrackDisplayElement utility function (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <title>Tests that the cue display tree has been removed properly and no crash ha ppens.</title> 2 <title>Tests that the cue display tree has been removed properly and no crash ha ppens.</title>
3 <script src="../media-file.js"></script> 3 <script src="../media-file.js"></script>
4 <script src="../media-controls.js"></script> 4 <script src="../media-controls.js"></script>
5 <script src="../../resources/testharness.js"></script> 5 <script src="../../resources/testharness.js"></script>
6 <script src="../../resources/testharnessreport.js"></script> 6 <script src="../../resources/testharnessreport.js"></script>
7 <video> 7 <video>
8 <track src="captions-webvtt/captions.vtt" kind="captions" mode="showing"> 8 <track src="captions-webvtt/captions.vtt" kind="captions" mode="showing">
9 </video> 9 </video>
10 <script> 10 <script>
11 async_test(function(t) { 11 async_test(function(t) {
12 var video = document.querySelector("video"); 12 var video = document.querySelector("video");
13 video.src = findMediaFile("video", "../content/test"); 13 video.src = findMediaFile("video", "../content/test");
14 14
15 video.play(); 15 video.play();
16 video.oncanplaythrough = t.step_func_done(function() { 16 video.oncanplaythrough = t.step_func_done(function() {
17 // Empty the contents of the video element when it is ready to play. 17 // Empty the contents of the video element when it is ready to play.
18 video.textContent = ""; 18 video.textContent = "";
19 19
20 // Text track should not be rendered anymore. 20 // Text track should not be rendered anymore.
21 assert_throws(null, function() { textTrackDisplayElement(video, "display "); }); 21 assert_throws(null, function() { textTrackDisplayElement(video); });
22 }); 22 });
23 }); 23 });
24 </script> 24 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698