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

Side by Side Diff: third_party/WebKit/LayoutTests/media/track/track-webvtt-tc016-align-positioning.html

Issue 2683633006: [WebVTT] Rename Middle to Center (Closed)
Patch Set: fix tests Created 3 years, 10 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 cue text position and alignment from settings.</title> 2 <title>Tests cue text position and alignment from settings.</title>
3 <script src="track-helpers.js"></script> 3 <script src="track-helpers.js"></script>
4 <script src="../../resources/testharness.js"></script> 4 <script src="../../resources/testharness.js"></script>
5 <script src="../../resources/testharnessreport.js"></script> 5 <script src="../../resources/testharnessreport.js"></script>
6 <video> 6 <video>
7 <track src="captions-webvtt/tc016-align-positioning.vtt"> 7 <track src="captions-webvtt/tc016-align-positioning.vtt">
8 <track src="captions-webvtt/tc016-align-positioning-bad.vtt"> 8 <track src="captions-webvtt/tc016-align-positioning-bad.vtt">
9 </video> 9 </video>
10 <script> 10 <script>
(...skipping 14 matching lines...) Expand all
25 return; 25 return;
26 26
27 testTrack(0); 27 testTrack(0);
28 testTrackError(1); 28 testTrackError(1);
29 t.done(); 29 t.done();
30 } 30 }
31 31
32 function testTrack(index) { 32 function testTrack(index) {
33 var expected = [ 33 var expected = [
34 { position : 10, align : "start" }, 34 { position : 10, align : "start" },
35 { position : 20, align : "middle" }, 35 { position : 20, align : "center" },
36 { position : 80, align : "end" } 36 { position : 80, align : "end" }
37 ]; 37 ];
38 38
39 assert_cues_match(video.textTracks[index].cues, expected); 39 assert_cues_match(video.textTracks[index].cues, expected);
40 } 40 }
41 41
42 function testTrackError(index) { 42 function testTrackError(index) {
43 var expected = [ 43 var expected = [
44 { position : 10, align : "middle" }, 44 { position : 10, align : "center" },
45 { position : "auto", align : "middle" }, 45 { position : "auto", align : "center" },
46 { position : "auto", align : "middle" } 46 { position : "auto", align : "center" }
47 ]; 47 ];
48 48
49 assert_cues_match(video.textTracks[index].cues, expected); 49 assert_cues_match(video.textTracks[index].cues, expected);
50 } 50 }
51 }); 51 });
52 </script> 52 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698