mirror of
https://github.com/servo/servo.git
synced 2025-08-23 22:35:33 +01:00
Update web-platform-tests to revision dc5cbf088edcdb266541d4e5a76149a2c6e716a0
This commit is contained in:
parent
1d40075f03
commit
079092dfea
2381 changed files with 90360 additions and 17722 deletions
|
@ -1,32 +0,0 @@
|
|||
// This file is duplicated verbatim from:
|
||||
// service-workers/service-worker/resources/get-host-info.sub.js
|
||||
// with the rationale that:
|
||||
// - it's better to not reinvent this
|
||||
// - at the same time, referencing tests deep inside a sibling test group is
|
||||
// not a great idea and copying the file is the lesser evil.
|
||||
function get_host_info() {
|
||||
var ORIGINAL_HOST = '127.0.0.1';
|
||||
var REMOTE_HOST = 'localhost';
|
||||
var UNAUTHENTICATED_HOST = 'example.test';
|
||||
var HTTP_PORT = 8000;
|
||||
var HTTPS_PORT = 8443;
|
||||
try {
|
||||
// In W3C test, we can get the hostname and port number in config.json
|
||||
// using wptserve's built-in pipe.
|
||||
// http://wptserve.readthedocs.org/en/latest/pipes.html#built-in-pipes
|
||||
HTTP_PORT = eval('{{ports[http][0]}}');
|
||||
HTTPS_PORT = eval('{{ports[https][0]}}');
|
||||
ORIGINAL_HOST = eval('\'{{host}}\'');
|
||||
REMOTE_HOST = 'www1.' + ORIGINAL_HOST;
|
||||
} catch (e) {
|
||||
}
|
||||
return {
|
||||
HTTP_ORIGIN: 'http://' + ORIGINAL_HOST + ':' + HTTP_PORT,
|
||||
HTTPS_ORIGIN: 'https://' + ORIGINAL_HOST + ':' + HTTPS_PORT,
|
||||
HTTPS_ORIGIN_WITH_CREDS: 'https://foo:bar@' + ORIGINAL_HOST + ':' + HTTPS_PORT,
|
||||
HTTP_REMOTE_ORIGIN: 'http://' + REMOTE_HOST + ':' + HTTP_PORT,
|
||||
HTTPS_REMOTE_ORIGIN: 'https://' + REMOTE_HOST + ':' + HTTPS_PORT,
|
||||
HTTPS_REMOTE_ORIGIN_WITH_CREDS: 'https://foo:bar@' + REMOTE_HOST + ':' + HTTPS_PORT,
|
||||
UNAUTHENTICATED_ORIGIN: 'http://' + UNAUTHENTICATED_HOST + ':' + HTTP_PORT
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue