Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / appcache / wrong-signature.html
blob2e572b441c9c65f621021ec37fd84d89d36e103a
1 <html manifest="resources/wrong-signature.manifest">
2 <script src="/js-test-resources/js-test.js"></script>
3 <script>
4 var jsTestIsAsync = true;
5 description("Test that a manifest served with a wrong signature isn't treated as such.");
7 function unexpectedEvent(name)
9 testFailed("Unexpected " + name + " event.");
10 finishJSTest();
13 function test(e)
15 shouldBe("window.applicationCache.status", "applicationCache.UNCACHED");
17 event = e;
18 shouldBeEqualToString("event.reason", "signature");
19 shouldBeEqualToString("event.url", "");
20 shouldBe("event.status", "0");
21 shouldBeTrue("'message' in event");
23 finishJSTest();
26 applicationCache.addEventListener('cached', function() { unexpectedEvent("cached"); }, false);
27 applicationCache.addEventListener('noupdate', function() { unexpectedEvent("noupdate"); }, false);
28 applicationCache.addEventListener('error', test, false);
30 </script>
31 </body>
32 </html>