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:
- /fetch/compression-dictionary/dictionary-clear-site-data-cookies.tentative.https.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<head>
<meta charset="utf-8">
<meta name="timeout" content="long"/>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="./resources/compression-dictionary-util.js"></script>
</head>
<body>
<script>
compression_dictionary_promise_test(async (t) => {
const dict = await (await fetch(kRegisterDictionaryPath)).text();
// Wait until `available-dictionary` header is available.
assert_equals(
await waitUntilAvailableDictionaryHeader(t, {}),
kDefaultDictionaryHashBase64);
// Clear site data.
assert_equals(await clearSiteData(/*directive=*/'cookies'), 'OK');
// Check if `available-dictionary` header is not available.
assert_equals(
await waitUntilAvailableDictionaryHeader(t, {max_retry: 0}),
'"available-dictionary" header is not available');
}, 'Clear-Site-Data with "cookies" directive must unregister dictionary');
</script>
</body>