diff --git a/fetch/compression-dictionary/dictionary-fetch-with-link-element-crossorigin.tentative.https.html b/fetch/compression-dictionary/dictionary-fetch-with-link-element-crossorigin.tentative.https.html new file mode 100644 index 00000000000000..fcc321840bace4 --- /dev/null +++ b/fetch/compression-dictionary/dictionary-fetch-with-link-element-crossorigin.tentative.https.html @@ -0,0 +1,74 @@ + +compression-dictionary + + + + + + + diff --git a/fetch/compression-dictionary/resources/dummy b/fetch/compression-dictionary/resources/dummy new file mode 100644 index 00000000000000..e69de29bb2d1d6 diff --git a/fetch/compression-dictionary/resources/empty.https.html b/fetch/compression-dictionary/resources/empty.https.html new file mode 100644 index 00000000000000..0e76edd65b7baf --- /dev/null +++ b/fetch/compression-dictionary/resources/empty.https.html @@ -0,0 +1 @@ + diff --git a/fetch/compression-dictionary/resources/fetch-options-worker.js b/fetch/compression-dictionary/resources/fetch-options-worker.js new file mode 100644 index 00000000000000..01ee48f982615c --- /dev/null +++ b/fetch/compression-dictionary/resources/fetch-options-worker.js @@ -0,0 +1,13 @@ +self.addEventListener('fetch', function(event) { + if (event.request.url.includes('dummy')) { + const params = new URL(event.request.url).searchParams; + const credentials = params.get("credentials"); + const mode = params.get("mode"); + if ((!mode || mode == event.request.mode) && + (!credentials || credentials == event.request.credentials)) { + event.respondWith(fetch(event.request)); + } else { + event.respondWith(Response.error()); + } + } +});