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

Side by Side Diff: LayoutTests/http/tests/media/track/track-webvtt-slow-loading-2.html

Issue 64303004: Handle buffer boundaries in the WebVTT parser (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix compilation warning Created 7 years, 1 month 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
« no previous file with comments | « no previous file | LayoutTests/http/tests/media/track/track-webvtt-slow-loading-2-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!doctype html> 1 <!doctype html>
2 <title>Slow loading WebVTT file interrupted just after a cue text linebreak</tit le> 2 <title>Slow loading WebVTT file interrupted in the middle of a timestamp line</t itle>
3 <script src=/media-resources/video-test.js></script> 3 <script src=/media-resources/video-test.js></script>
4 <script> 4 <script>
5 function loadAndStall() 5 function loadAndStall()
6 { 6 {
7 return "http://127.0.0.1:8000/resources/load-and-stall.php"; 7 return "http://127.0.0.1:8000/resources/load-and-stall.php";
8 } 8 }
9 9
10 function vttTrack() 10 function vttTrack()
11 { 11 {
12 return "?name=../../../media/track/captions-webvtt/captions-multiline-lf.vtt &mimeType=text%2Fvtt"; 12 return "?name=../../../media/track/captions-webvtt/captions-multiline-lf.vtt &mimeType=text%2Fvtt";
13 } 13 }
14 14
15 window.onload = function() 15 window.onload = function()
16 { 16 {
17 video = document.createElement('video'); 17 video = document.createElement('video');
18 track = document.createElement('track'); 18 track = document.createElement('track');
19 video.appendChild(track); 19 video.appendChild(track);
20 track.onload = function() { 20 track.onload = function() {
21 testExpected("track.track.cues.length", 2, "==="); 21 testExpected("track.track.cues.length", 2, "===");
22 testExpected("track.track.cues[0].text", 'Lorem\u000aipsum', "==="); 22 testExpected("track.track.cues[0].text", 'Lorem\u000aipsum', "===");
23 endTest(); 23 endTest();
24 }; 24 };
25 track.onerror = function() { 25 track.onerror = function() {
26 failTest(); 26 failTest();
27 }; 27 };
28 track.src = loadAndStall() + vttTrack() + "&stallAt=49&stallFor=1"; 28 track.src = loadAndStall() + vttTrack() + "&stallAt=32&stallFor=1";
29 track.track.mode = "hidden"; 29 track.track.mode = "hidden";
30 } 30 }
31 </script> 31 </script>
32 <p>Slow loading WebVTT file interrupted just after a cue text linebreak.</p> 32 <p>Slow loading WebVTT file interrupted in the middle of a timestamp line.</p>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/http/tests/media/track/track-webvtt-slow-loading-2-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698