Source code
Revision control
Copy as Markdown
Other Tools
Test Info: Warnings
- This test has a WPT meta file that expects 1 subtest issues.
- This WPT test may be referenced by the following Test IDs:
- /shared-storage/run-operation-in-detached-frame.tentative.https.sub.html - WPT Dashboard Interop Dashboard
<!doctype html>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<body>
<iframe></iframe>
<script>
promise_test(async t => {
const iframe = document.querySelector('iframe');
const childSharedStorage = iframe.contentWindow.sharedStorage;
iframe.remove();
try {
await childSharedStorage.run("operation1");
} catch (e) {
assert_equals(e.name, 'InvalidAccessError');
return;
}
assert_unreached("did not reject");
}, 'run() when frame is detached');
</script>
</body>