test(service-worker): support mock requests with null/empty client ID (#23625)
PR Close #23625
This commit is contained in:

committed by
Alex Rickabaugh

parent
b004be5169
commit
3df879fe17
@ -721,7 +721,8 @@ const manifestUpdateHash = sha1(JSON.stringify(manifestUpdate));
|
||||
})();
|
||||
|
||||
async function makeRequest(
|
||||
scope: SwTestHarness, url: string, clientId = 'default', init?: Object): Promise<string|null> {
|
||||
scope: SwTestHarness, url: string, clientId: string | null = 'default',
|
||||
init?: Object): Promise<string|null> {
|
||||
const [resPromise, done] = scope.handleFetch(new MockRequest(url, init), clientId);
|
||||
await done;
|
||||
const res = await resPromise;
|
||||
|
Reference in New Issue
Block a user