Update web-platform-tests to revision 1e42017386ce1eaeed4925fb8bc7f5417752019a

This commit is contained in:
Ms2ger 2016-07-05 17:05:14 +02:00
parent 5574a4e4c8
commit a972fdb353
2003 changed files with 16788 additions and 3140 deletions

View file

@ -79,7 +79,7 @@ async_test(function(){
var video = document.createElement('video');
var t1 = video.addTextTrack('subtitles');
var t1_cues = t1.cues;
t1.mode = 'showing';
t1.mode = 'hidden';
var track = document.createElement('track');
track['default'] = true;
video.appendChild(track); // queues a task to "honor user preferences...", media element event task source

View file

@ -0,0 +1,45 @@
<!DOCTYPE HTML>
<html>
<head>
<title>HTML5 Media Elements: 'media' attribute</title>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
<link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
<link rel="help" href="http://www.w3.org/TR/html5/video.html#the-source-element" />
<meta name="assert" content="'media' attribute is 'all' by default." />
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script type="text/javascript" src="/common/media.js"></script>
<script type="text/javascript">
var videotest = async_test();
function do_play(event)
{
videotest.step(function() {
var vid = document.getElementById("video0");
assert_true(vid.currentSrc.indexOf("movie_300") > 0);
});
videotest.done();
}
</script>
</head>
<body>
<div id='log'></div>
<video id="video0" autoplay onplay="do_play(event);">
<script type="text/javascript">
document.write(
"<source media='not all' src='" + getVideoURI("/media/movie_300") + "'" +
" />"
);
document.write(
"<source src='" + getVideoURI("/media/movie_5") + "'" +
" media='all' />"
);
</script>
Your browser does not support media elements.
</video>
</body>
</html>

View file

@ -0,0 +1,17 @@
<!doctype html>
<meta charset=utf-8>
<title>Historical canvas features</title>
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<div id=log></div>
<script>
var canvas;
setup(function() {
canvas = document.createElement("canvas");
});
["supportsContext", "probablySupportsContext"].forEach(function(m) {
test(function() {
assert_false(m in canvas);
}, "Canvas support for " + m);
});
</script>

View file

@ -48,6 +48,8 @@
});
}, "iframe-sandbox-allowfullscreen");
/* Fullscreen enabled flag with dialog */
function test_allowfullscreen_dialog(t, setup_iframe, check) {
var iframe = document.createElement("iframe");
setup_iframe(iframe);
@ -86,4 +88,28 @@
assert_false(newWin.document.fullscreenEnabled, "Document in the new window should inherit the sandboxed fullscreen flag and should not have fullscreen enabled flag set");
});
}, "iframe-sandbox-allowfullscreen-dialog");
/* Fullscreen enabled flag with about:blank */
function test_allowfullscreen_noload(setup_iframe, check) {
var iframe = document.createElement("iframe");
setup_iframe(iframe);
document.body.appendChild(iframe);
check(iframe.contentDocument);
document.body.removeChild(iframe);
}
test(function() {
test_allowfullscreen_noload(function() {}, function(doc) {
assert_false(doc.fullscreenEnabled, "Fullscreen should not be enabled without allowfullscreen attribute");
});
}, "iframe-noload-noallowfullscreen");
test(function() {
test_allowfullscreen_noload(function(iframe) {
iframe.setAttribute("allowfullscreen", true);
}, function(doc) {
assert_true(doc.fullscreenEnabled, "Fullscreen should be enabled with allowfullscreen attribute");
});
}, "iframe-noload-allowfullscreen");
</script>

View file

@ -25,6 +25,21 @@ async_test(function(t) {
document.body.appendChild(obj);
}, "error event");
async_test(function(t) {
var obj = document.createElement("object");
obj.onerror = t.step_func_done(function(e){
assert_equals(e.target, obj,
"The error event should be fired on our element");
});
obj.onload = t.step_func_done(function(e){
assert_unreached("The load event should not be fired.");
});
obj.data = "http://test:test";
document.body.appendChild(obj);
}, "error event");
async_test(function(t) {
var obj = document.createElement("object");
obj.onload = t.step_func_done(function(e){