Update web-platform-tests to revision b'468d01bbd84da2babf265c6af46947be68713440'

This commit is contained in:
WPT Sync Bot 2021-09-07 11:16:33 +00:00 committed by cybai
parent 35e95f55a1
commit 58e8ee674b
9438 changed files with 266112 additions and 106976 deletions

View file

@ -122,11 +122,13 @@ function fetchInit (requests, config) {
'headers': []
}
if ('request_method' in config) init.method = config['request_method']
if ('request_headers' in config) init.headers = config['request_headers']
// Note: init.headers must be a copy of config['request_headers'] array,
// because new elements are added later.
if ('request_headers' in config) init.headers = [...config['request_headers']];
if ('name' in config) init.headers.push(['Test-Name', config.name])
if ('request_body' in config) init.body = config['request_body']
if ('mode' in config) init.mode = config['mode']
if ('credentials' in config) init.mode = config['credentials']
if ('credentials' in config) init.credentials = config['credentials']
if ('cache' in config) init.cache = config['cache']
init.headers.push(['Test-Requests', btoa(JSON.stringify(requests))])
return init