mirror of
https://github.com/servo/servo.git
synced 2025-08-23 14:25:33 +01:00
Update web-platform-tests to revision e8bfc205e36ad699601212cd50083870bad9a75d
This commit is contained in:
parent
65dd6d4340
commit
ccdb0a3458
1428 changed files with 118036 additions and 9786 deletions
|
@ -0,0 +1,2 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Current page used as a test helper</title>
|
|
@ -0,0 +1,17 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Incumbent page used as a test helper</title>
|
||||
|
||||
<iframe src="../current/current.html" id="c"></iframe>
|
||||
<iframe src="../relevant/relevant.html" id="r"></iframe>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
|
||||
const current = document.querySelector('#c').contentWindow;
|
||||
const relevant = document.querySelector('#r').contentWindow;
|
||||
|
||||
window.createRedirectResponse = (...args) => {
|
||||
return current.Response.redirect.call(relevant.Response, ...args);
|
||||
};
|
||||
|
||||
</script>
|
|
@ -0,0 +1,2 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Relevant page used as a test helper</title>
|
|
@ -0,0 +1,27 @@
|
|||
<!DOCTYPE html>
|
||||
<title>Response.redirect URL parsing, with multiple globals in play</title>
|
||||
<link rel="help" href="https://fetch.spec.whatwg.org/#dom-response-redirect">
|
||||
<link rel="author" title="Domenic Denicola" href="mailto:d@domenic.me">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<!-- This is the entry global -->
|
||||
|
||||
<iframe src="incumbent/incumbent.html"></iframe>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
|
||||
const loadPromise = new Promise(resolve => {
|
||||
window.addEventListener("load", () => resolve());
|
||||
});
|
||||
|
||||
promise_test(() => {
|
||||
return loadPromise.then(() => {
|
||||
const res = frames[0].createRedirectResponse("url");
|
||||
|
||||
assert_equals(res.headers.get("Location"), new URL("current/url", location.href).href);
|
||||
});
|
||||
}, "should parse the redirect Location URL relative to the current settings object");
|
||||
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue