mirror of
https://github.com/servo/servo.git
synced 2025-06-29 03:23:41 +01:00
Update web-platform-tests to revision 4cec5596c806088cd8f1781bdaab1d10abb72394
This commit is contained in:
parent
58f3766c5b
commit
57fbf23022
95 changed files with 1292 additions and 700 deletions
|
@ -29,14 +29,15 @@ const remoteOrigin = "http://{{domains[www1]}}:{{ports[http][0]}}/";
|
|||
test(t => {
|
||||
assert_equals(
|
||||
referrerSame, location.href,
|
||||
"Referrer should be sent for the same-origin top-level script.");
|
||||
"Full referrer should be sent for the same-origin top-level script.");
|
||||
}, "Importing a same-origin top-level script with the " +
|
||||
"origin-when-cross-origin policy.");
|
||||
|
||||
test(t => {
|
||||
assert_equals(
|
||||
referrerRemote, origin,
|
||||
"Referrer should be sent for the remote-origin top-level script.");
|
||||
"Referrer should be stripped to the origin when importing " +
|
||||
"remote-origin top-level script.");
|
||||
}, "Importing a remote-origin top-level script with the " +
|
||||
"origin-when-cross-origin policy.");
|
||||
|
||||
|
@ -45,31 +46,34 @@ test(t => {
|
|||
new URL("resources/import-referrer-checker.sub.js", location.href)
|
||||
assert_equals(
|
||||
referrerSameSame, scriptURL + "?name=same_same",
|
||||
"Referrer should be sent for the same-origin descendant script.");
|
||||
"Full referrer should be sent for same-origin descendant script" +
|
||||
"imported by same-origin top-level script.");
|
||||
}, "Importing a same-origin descendant script from a same-origin top-level " +
|
||||
"script with the origin-when-cross-origin policy.");
|
||||
|
||||
test(t => {
|
||||
assert_equals(
|
||||
referrerSameRemote, origin,
|
||||
"Referrer should be sent for the remote-origin descendant script.");
|
||||
"Referrer should be stripped to the origin for the remote-origin " +
|
||||
"descendant script imported from same-origin top-level script.");
|
||||
}, "Importing a remote-origin descendant script from a same-origin top-level " +
|
||||
"script with the origin-when-cross-origin policy.");
|
||||
|
||||
test(t => {
|
||||
assert_equals(
|
||||
referrerRemoteRemote, remoteOrigin,
|
||||
"Referrer should be sent for the remote-origin descendant script.");
|
||||
const scriptURL = new URL(
|
||||
"html/semantics/scripting-1/the-script-element/module/resources/" +
|
||||
"import-referrer-checker.sub.js",
|
||||
remoteOrigin);
|
||||
assert_equals(referrerRemoteRemote, scriptURL + "?name=remote_remote",
|
||||
"Full referrer should be sent for the remote-origin descendant script " +
|
||||
"imported from a remote-origin top-level script.");
|
||||
}, "Importing a remote-origin descendant script from a remote-origin " +
|
||||
"top-level script with the origin-when-cross-origin policy.");
|
||||
|
||||
test(t => {
|
||||
const scriptURL = new URL(
|
||||
"html/semantics/scripting-1/the-script-element/module/resources/" +
|
||||
"import-same-origin-referrer-checker-from-remote-origin.sub.js",
|
||||
remoteOrigin);
|
||||
assert_equals(referrerRemoteSame, scriptURL + "?name=remote_same",
|
||||
"Referrer should be sent for the same-origin descendant script.");
|
||||
assert_equals(referrerRemoteSame, remoteOrigin,
|
||||
"Referrer should be stripped to the origin for the same-origin " +
|
||||
"descendant script imported by remote-origin top-level script.");
|
||||
}, "Importing a same-origin descendant script from a remote-origin " +
|
||||
"top-level script with the origin-when-cross-origin policy.");
|
||||
|
||||
|
|
|
@ -54,22 +54,21 @@ test(t => {
|
|||
"script with the same-origin policy.");
|
||||
|
||||
test(t => {
|
||||
const scriptURL = new URL(
|
||||
"html/semantics/scripting-1/the-script-element/module/resources/" +
|
||||
"import-referrer-checker.sub.js", remoteOrigin);
|
||||
assert_equals(
|
||||
referrerRemoteRemote, "",
|
||||
"Referrer should not be sent for the remote-origin descendant script " +
|
||||
"even if it is imported from the script in the same remote-origin.");
|
||||
referrerRemoteRemote, scriptURL + "?name=remote_remote",
|
||||
"Referrer should be sent for the remote-origin descendant script " +
|
||||
"when it is imported from a top-level script in the same remote-origin.");
|
||||
}, "Importing a remote-origin descendant script from a remote-origin " +
|
||||
"top-level script with the same-origin policy.");
|
||||
|
||||
test(t => {
|
||||
const scriptURL = new URL(
|
||||
"html/semantics/scripting-1/the-script-element/module/resources/" +
|
||||
"import-same-origin-referrer-checker-from-remote-origin.sub.js",
|
||||
remoteOrigin);
|
||||
assert_equals(
|
||||
referrerRemoteSame, scriptURL + "?name=remote_same",
|
||||
"Referrer should be sent for the same-origin descendant script " +
|
||||
"even if it is imported from the script in the remote-origin.");
|
||||
referrerRemoteSame, "",
|
||||
"Referrer should not be sent for the same-origin descendant script " +
|
||||
"when it is imported from a top-level remote-origin script.");
|
||||
}, "Importing a same-origin descendant script from a remote-origin " +
|
||||
"top-level script with the same-origin policy.");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue