Index: third_party/WebKit/LayoutTests/media/track/track-webvtt-tc026-voice.html |
diff --git a/third_party/WebKit/LayoutTests/media/track/track-webvtt-tc026-voice.html b/third_party/WebKit/LayoutTests/media/track/track-webvtt-tc026-voice.html |
index f6f0239f542d5b7271cd37b6a03916a657a7e92c..1d999a18939e23679ca97870b7033010c0450a9f 100644 |
--- a/third_party/WebKit/LayoutTests/media/track/track-webvtt-tc026-voice.html |
+++ b/third_party/WebKit/LayoutTests/media/track/track-webvtt-tc026-voice.html |
@@ -4,11 +4,13 @@ |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
<script src=../media-file.js></script> |
+ <!-- TODO(philipj): Convert test to testharness.js. crbug.com/588956 |
+ (Please avoid writing new tests using video-test.js) --> |
<script src=../video-test.js></script> |
- <script> |
+ <script> |
var numberOfTrackTests = 2; |
- |
+ |
function trackLoaded() |
{ |
numberOfTracksLoaded++; |
@@ -17,12 +19,12 @@ |
testTrackError(1); |
} |
} |
- |
+ |
function testTrack(i) |
{ |
findMediaElement(); |
testExpected("video.textTracks[" + i + "].cues.length", "3"); |
- |
+ |
var fragment = document.createDocumentFragment(); |
var cspan = document.createElement("span"); |
cspan.className = "blue"; |
@@ -30,18 +32,18 @@ |
cspan.appendChild(document.createTextNode("Bear is Coming!!!!!")); |
fragment.appendChild(cspan); |
fragment.appendChild(document.createTextNode("\nText span with a class and an annotation.")); |
- |
+ |
testExpected(fragment.isEqualNode(video.textTracks[i].cues[0].getCueAsHTML()), true); |
- |
+ |
fragment = document.createDocumentFragment(); |
cspan = document.createElement("span"); |
cspan.title = "Doe Hunter"; |
cspan.appendChild(document.createTextNode("I said Bear is coming!!!!")); |
fragment.appendChild(cspan); |
- |
+ |
testExpected(fragment.isEqualNode(video.textTracks[i].cues[1].getCueAsHTML()), true); |
- |
+ |
fragment = document.createDocumentFragment(); |
fragment.appendChild(document.createTextNode("I said ")); |
cspan = document.createElement("span"); |
@@ -50,7 +52,7 @@ |
cspan.appendChild(document.createTextNode("Bear is coming now")); |
fragment.appendChild(cspan); |
fragment.appendChild(document.createTextNode("!!!!")); |
- |
+ |
testExpected(fragment.isEqualNode(video.textTracks[i].cues[2].getCueAsHTML()), true); |
allTestsEnded(); |
@@ -60,14 +62,14 @@ |
{ |
findMediaElement(); |
testExpected("video.textTracks[" + i + "].cues.length", "3"); |
- |
+ |
var fragment = document.createDocumentFragment(); |
fragment.appendChild(document.createTextNode("Bear is Coming!!!!!")); |
fragment.appendChild(document.createTextNode("\nThis is two annotations for an empty tag.")); |
testExpected(fragment.isEqualNode(video.textTracks[i].cues[0].getCueAsHTML()), true); |
- |
+ |
fragment = document.createDocumentFragment(); |
fragment.appendChild(document.createTextNode("I said Bear is coming!!!!")); |
fragment.appendChild(document.createTextNode("\nThis does not parse as a voice tag.")); |
@@ -87,9 +89,9 @@ |
</head> |
<body onload="enableAllTextTracks()"> |
<p>Tests cues with voice markup <v>.</p> |
- <video> |
+ <video> |
<track src="captions-webvtt/tc026-voice.vtt" onload="trackLoaded()"> |
<track src="captions-webvtt/tc026-voice-bad.vtt" onload="trackLoaded()"> |
</video> |
</body> |
-</html> |
+</html> |