Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / media / track / track-webvtt-slow-loading-2.html
bloba1ea951a2c20f8d104e0d90a668a4d60311c195f
1 <!doctype html>
2 <title>Slow loading WebVTT file interrupted in the middle of a timestamp line</title>
3 <script src=/media-resources/video-test.js></script>
4 <script>
5 function loadAndStall()
7 return "http://127.0.0.1:8000/resources/load-and-stall.php";
10 function vttTrack()
12 return "?name=../../../media/track/captions-webvtt/captions-multiline-lf.vtt&mimeType=text%2Fvtt";
15 window.onload = function()
17 video = document.createElement('video');
18 track = document.createElement('track');
19 video.appendChild(track);
20 track.onload = function() {
21 testExpected("track.track.cues.length", 2, "===");
22 testExpected("track.track.cues[0].text", 'Lorem\u000aipsum', "===");
23 endTest();
25 track.onerror = function() {
26 failTest();
28 track.src = loadAndStall() + vttTrack() + "&stallAt=32&stallFor=1";
29 track.track.mode = "hidden";
31 </script>
32 <p>Slow loading WebVTT file interrupted in the middle of a timestamp line.</p>