timings-negative.test (697B)
1 timings, negative 2 <link rel="help" href="https://w3c.github.io/webvtt/#collect-a-webvtt-timestamp"> 3 4 assert_equals(cues.length, 4); 5 6 [ 7 [0, 0], 8 [1, 0.999], 9 [60, 59.999], 10 [3600, 3599.999], 11 ].forEach(function(pair, index) { 12 var startTime = pair[0]; 13 var endTime = pair[1]; 14 15 assert_equals(cues[index].text, 'text' + index, 'Failed with cue ' + index); 16 assert_equals(cues[index].startTime, startTime, 'Failed with cue ' + index); 17 assert_equals(cues[index].endTime, endTime, 'Failed with cue ' + index); 18 }); 19 20 === 21 WEBVTT 22 23 00:00:00.000 --> 00:00:00.000 24 text0 25 26 00:00:01.000 --> 00:00:00.999 27 text1 28 29 00:01:00.000 --> 00:00:59.999 30 text2 31 32 01:00:00.000 --> 00:59:59.999 33 text3