diff options
Diffstat (limited to 'testing/web-platform/tests/appmanifest/id-member/id-member-service-worker.js')
-rw-r--r-- | testing/web-platform/tests/appmanifest/id-member/id-member-service-worker.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/testing/web-platform/tests/appmanifest/id-member/id-member-service-worker.js b/testing/web-platform/tests/appmanifest/id-member/id-member-service-worker.js new file mode 100644 index 0000000000..c0a16c4a46 --- /dev/null +++ b/testing/web-platform/tests/appmanifest/id-member/id-member-service-worker.js @@ -0,0 +1,8 @@ +// Some user agents only offer app installation if there is a SW and it handles +// offline requests. + +self.addEventListener("fetch", e => { + e.respondWith(fetch(e.request).catch(_ => { + return new Response('Offline test.'); + })); +}); |