mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
45 lines
1.4 KiB
HTML
45 lines
1.4 KiB
HTML
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<title>bad manifest content type</title>
|
|
|
|
<script type="text/javascript" src="/MochiKit/packed.js"></script>
|
|
<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
|
|
|
<script type="text/javascript">
|
|
|
|
function expectInvalidState(fn, desc) {
|
|
var gotInvalidState = false;
|
|
try {
|
|
fn();
|
|
} catch(e) {
|
|
if (e.code == DOMException.INVALID_STATE_ERR) {
|
|
gotInvalidState = true;
|
|
}
|
|
}
|
|
|
|
ok(gotInvalidState, desc);
|
|
}
|
|
|
|
is(typeof(applicationCache), "object");
|
|
is(applicationCache.length, 0, "applicationCache.length should be 0");
|
|
is(applicationCache.status, 0, "applicationCache.status should be 0 (UNCACHED)");
|
|
|
|
expectInvalidState(function() { applicationCache.add("http://localhost:8888/MochiKit/packed.js"); },
|
|
"applicationCache.add should throw INVALID_STATE_ERR");
|
|
expectInvalidState(function() { applicationCache.remove("http://localhost:8888/MochiKit/packed.js"); },
|
|
"applicationCache.remove should throw INVALID_STATE_ERR");
|
|
expectInvalidState(function() { applicationCache.update(); },
|
|
"applicationCache.update should throw INVALID_STATE_ERR");
|
|
expectInvalidState(function() { applicationCache.swapCache(); },
|
|
"applicationCache.update should throw INVALID_STATE_ERR");
|
|
|
|
|
|
</script>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
</body>
|
|
</html>
|