Skip to content

Commit

Permalink
Bug 1510914 [wpt PR 14288] - Test when a SW replies with a fetch from…
Browse files Browse the repository at this point in the history
… a different URL, a=testonly

Automatic update from web-platform-tests
Test navigation when a SW replies with a fetch from a different URL (#14288)

The resulting document's location should be the originally requested
URL. See also whatwg/html#4205
--

wpt-commits: 38eec61c5e43b9757351d63c55205fa2d8d3bb2d
wpt-pr: 14288

UltraBlame original commit: 44cd01e40fe7de4a055a200dcec4c7c40102dba7
  • Loading branch information
marco-c committed Oct 3, 2019
1 parent cd9c2b6 commit fc0740a
Showing 1 changed file with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -668,6 +668,24 @@
'SW-fetched redirect to other-origin in-scope.');


// SW responds with a fetch from a different url.
// SW: event.respondWith(fetch(params['url']));
url2 = SCOPE1;
url1 = SCOPE1 + 'sw=fetch-url&url=' + encodeURIComponent(url2);
redirect_test(
url1,
url1,
[
[
{url: url1, resultingClientIdTag: 'x'}
],
[],
[]
],
'x',
'SW-fetched response from different URL, same-origin same-scope.');


// Opaque redirect.
// SW: event.respondWith(fetch(
// new Request(event.request.url, {redirect: 'manual'})));
Expand Down

0 comments on commit fc0740a

Please sign in to comment.