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

@ -11,12 +11,19 @@
<script>
var cache = window.applicationCache;
test(function() {
try {
async_test(function(t) {
var next = t.step_func(function() {
cache.onnoupdate = cache.oncached = null;
cache.update()
assert_true(true, "update method test")
} catch (e) {
assert_unreached("update method failed.");
t.done();
});
if (cache.status === cache.IDLE) {
next();
} else {
cache.onnoupdate = cache.oncached = next;
}
});
</script>

View file

@ -1,16 +1,11 @@
<!DOCTYPE HTML>
<html manifest="../resources/manifest/clock.manifest">
<html manifest="./non-existent-file.manifest">
<head>
<title>Offline Application Cache - API_update_error</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
</head>
<body>
<ol>
<li>Remove the manifest file (manifest/clock.manifest) from the server.</li>
<li>Refresh the page, then calling update() will throw InvalidStateError exception.</li>
</ol>
<div id="log"></div>
<script>

View file

@ -0,0 +1,19 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>AppCache should not exist in shared workers, even though it was specced at some point</title>
<link rel="help" href="https://github.com/whatwg/html/pull/2384">
<link rel="author" title="Domenic Denicola" href="mailto:d@domenic.me">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
"use strict";
if (typeof SharedWorker === "undefined") {
test(() => {
}, "This browser doesn't implement SharedWorker, and so passes this test automatically");
} else {
fetch_tests_from_worker(new SharedWorker("no-appcache-in-shared-workers-historical.js"));
}
</script>

View file

@ -0,0 +1,14 @@
"use strict";
self.importScripts('/resources/testharness.js');
test(() => {
assert_equals(self.applicationCache, undefined, "self.applicationCache must be undefined");
assert_false("applicationCache" in self, "applicationCache must not even be a property of self");
}, "self.applicationCache must not exist");
test(() => {
assert_equals(self.ApplicationCache, undefined, "self.ApplicationCache must be undefined");
assert_false("ApplicationCache" in self, "ApplicationCache must not even be a property of self");
}, "ApplicationCache must not be exposed");
done();