mirror of
https://github.com/videojs/video.js.git
synced 2024-12-27 02:43:45 +02:00
Added tests for cue parsing, including tests for #877
This commit is contained in:
parent
7aeb288848
commit
e3e836f41e
@ -13,4 +13,16 @@ test('should place title list item into ul', function() {
|
||||
ok(titleElement.innerHTML === 'Chapters', 'title element placed in ul');
|
||||
|
||||
player.dispose();
|
||||
});
|
||||
});
|
||||
|
||||
test('cue time parsing', function() {
|
||||
var parse = vjs.TextTrack.prototype.parseCueTime;
|
||||
|
||||
equal(parse('11:11'), 671, 'Only minutes and seconds (11:11)');
|
||||
equal(parse('11:11:11'), 40271, 'Hours, minutes, seconds (11:11:11)');
|
||||
equal(parse('11:11:11.111'), 40271.111, 'Hours, minutes, seconds, decimals (11:11:11.111)');
|
||||
|
||||
// Uncommment to test a fix for #877
|
||||
// equal(parse('11:11 line:90%'), 671, 'minutes, seconds with flags');
|
||||
// equal(parse('11:11:11 line:90%'), 40271, 'hours, minutes, seconds with flags');
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user