Update web-platform-tests to revision be5419e845d39089ba6dc338c1bd0fa279108317

This commit is contained in:
Josh Matthews 2018-01-04 13:44:24 -05:00
parent aa199307c8
commit 2b6f573eb5
3440 changed files with 109438 additions and 41750 deletions

View file

@ -0,0 +1,25 @@
<!doctype html>
<title>VTTCue constructor exceptions</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<div id=log></div>
<script>
test(function() {
assert_throws(new TypeError, function() { new VTTCue(NaN, 0, 'foo'); });
assert_throws(new TypeError, function() { new VTTCue(Infinity, 0, 'foo'); });
assert_throws(new TypeError, function() { new VTTCue('tomorrow', 0, 'foo'); });
}, document.title+', non-finite start time');
test(function() {
assert_throws(new TypeError, function() { new VTTCue(0, NaN, 'foo'); });
assert_throws(new TypeError, function() { new VTTCue(0, Infinity, 'foo'); });
assert_throws(new TypeError, function() { new VTTCue(0, 'tomorrow', 'foo'); });
}, document.title+', non-finite end time');
test(function() {
var start = { valueOf: function() { return 42; } };
var end = { valueOf: function() { return 84; } };
var cue = new VTTCue(start, end, 'bar');
assert_equals(cue.startTime, 42);
assert_equals(cue.endTime, 84);
assert_equals(cue.text, 'bar');
}, document.title+', valueOf');
</script>