Update web-platform-tests to revision 58eb04cecbbec2e18531ab440225e38944a9c444

This commit is contained in:
Josh Matthews 2017-04-17 12:06:02 +10:00 committed by Anthony Ramine
parent 25e8bf69e6
commit 665817d2a6
35333 changed files with 1818077 additions and 16036 deletions

View file

@ -2,5 +2,4 @@
@zqzhang
@zcorpan
@jdm
@Ms2ger
@mkruisselbrink

View file

@ -17,12 +17,22 @@ async_test(function(t) {
xhr.send();
xhr.onload = t.step_func(function() {
xhr.onload = t.step_func_done(function() {
assert_equals(xhr.response, "test");
t.done();
})
xhr.onerror = t.step_func(function() {
assert_unreached("Got unexpected error event");
})
});
</script>
}, "Revoke blob URL after open(), will fetch");
async_test(t => {
const blob = new Blob(["test"]),
blobURL = URL.createObjectURL(blob),
client = new XMLHttpRequest
URL.revokeObjectURL(blobURL)
client.open("GET", blobURL)
client.onload = t.step_func(() => assert_unreached("Got unexpected load event"))
client.onerror = t.step_func_done()
client.send()
}, "Revoke blob URL before open(), network error (after send())")
</script>

View file

@ -5,6 +5,7 @@
<title>Historical features</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
</head>
<body>
<div id="log"></div>
@ -48,6 +49,10 @@
assert_false('isClosed' in b, 'isClosed in b');
assert_false('isClosed' in Blob.prototype, 'isClosed in Blob.prototype');
}, 'Blob.close() should not be supported');
// Only add service worker test if service workers are actually supported.
if (navigator.serviceWorker)
service_worker_test('support/historical-serviceworker.js', 'Service worker test setup');
</script>
</body>
</html>

View file

@ -0,0 +1,5 @@
importScripts('/resources/testharness.js');
test(() => {
assert_false('FileReaderSync' in self);
}, '"FileReaderSync" should not be supported in service workers');