Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync WPT with upstream (16-01-2020) #25537

Merged
merged 1 commit into from Jan 16, 2020
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
The table of contents is too big for display.

Always

Just for now

The diff you're trying to view is too large. We only load the first 3000 changed files.

Large diffs are not rendered by default.

This file was deleted.

@@ -1,2 +1,2 @@
[no-transition-from-ua-to-blocking-stylesheet.html]
expected: FAIL
expected: TIMEOUT
@@ -0,0 +1,4 @@
[CaretPosition-001.html]
[Element at (400, 100)]
expected: FAIL

@@ -312,24 +312,21 @@
[fetch(): separate response Content-Type: text/plain ]
expected: NOTRUN

[<iframe>: separate response Content-Type: text/plain */*]
expected: FAIL

[<iframe>: separate response Content-Type: text/html;" \\" text/plain]
[<iframe>: combined response Content-Type: text/html */*]
expected: FAIL

[<iframe>: combined response Content-Type: text/html;" text/plain]
[<iframe>: combined response Content-Type: text/html;x=" text/plain]
expected: FAIL

[<iframe>: combined response Content-Type: */* text/html]
[<iframe>: combined response Content-Type: text/html;charset=gbk text/plain text/html]
expected: FAIL

[<iframe>: combined response Content-Type: text/html */*]
[<iframe>: separate response Content-Type: text/html;" text/plain]
expected: FAIL

[<iframe>: separate response Content-Type: text/html */*;charset=gbk]
[<iframe>: combined response Content-Type: text/html;" \\" text/plain]
expected: FAIL

[<iframe>: combined response Content-Type: text/html;x=" text/plain]
[<iframe>: separate response Content-Type: text/plain */*;charset=gbk]
expected: FAIL

@@ -53,6 +53,3 @@
[combined text/javascript ]
expected: FAIL

[separate text/javascript x/x]
expected: FAIL

@@ -14,6 +14,3 @@
[X-Content-Type-Options%3A%20%40%23%24%23%25%25%26%5E%26%5E*()()11!%2Cnosniff]
expected: FAIL

[X-Content-Type-Options%3A%20%22nosniFF%22]
expected: FAIL

@@ -0,0 +1,4 @@
[traverse_the_history_4.html]
[Multiple history traversals, last would be aborted]
expected: FAIL

@@ -0,0 +1,4 @@
[traverse_the_history_5.html]
[Multiple history traversals, last would be aborted]
expected: FAIL

@@ -1,6 +1,5 @@
[iframe_sandbox_popups_escaping-3.html]
type: testharness
expected: CRASH
[Check that popups from a sandboxed iframe escape the sandbox if\n allow-popups-to-escape-sandbox is used]
expected: TIMEOUT
expected: FAIL

@@ -429,3 +429,15 @@
[onwebkittransitionend: the default value must be null]
expected: FAIL

[onwebkittransitionend: the content attribute must execute when an event is dispatched]
expected: FAIL

[onwebkitanimationstart: the content attribute must execute when an event is dispatched]
expected: FAIL

[onwebkitanimationend: the content attribute must execute when an event is dispatched]
expected: FAIL

[onwebkitanimationiteration: the content attribute must execute when an event is dispatched]
expected: FAIL

@@ -10,3 +10,6 @@
[Verifies the resolution of entry.startTime is at least 20 microseconds.]
expected: TIMEOUT

[Verifies the resolution of performance.now() is at least 5 microseconds.]
expected: FAIL

@@ -22,7 +22,7 @@ const run_test = test => {
}, test.name + " precondition: Test that the browser does not have client " +
"hints preferences cached");

// Then, attempt to set Accept-CH-Lifetime for 1 second
// Then, attempt to set Accept-CH
promise_test(t => {
return new Promise(resolve => {
if (test.type == "navigation") {
@@ -1,3 +1,2 @@
Accept-CH: device-memory, DPR
Accept-CH-Lifetime: 1
Access-Control-Allow-Origin: *
@@ -261,9 +261,8 @@ def generate_test_source_files(spec_directory, spec_json, target):
expand_pattern(excluded_pattern, test_expansion_schema)
for excluded_selection in permute_expansion(excluded_expansion,
artifact_order):
excluded_selection_path = spec_json[
'selection_pattern'] % excluded_selection
exclusion_dict[excluded_selection_path] = True
excluded_selection['delivery_key'] = spec_json['delivery_key']
exclusion_dict[dump_test_parameters(excluded_selection)] = True

for spec in specification:
# Used to make entries with expansion="override" override preceding
@@ -276,20 +275,20 @@ def generate_test_source_files(spec_directory, spec_json, target):
for selection in permute_expansion(expansion, artifact_order):
selection['delivery_key'] = spec_json['delivery_key']
selection_path = spec_json['selection_pattern'] % selection
if not selection_path in exclusion_dict:
if selection_path in output_dict:
if expansion_pattern['expansion'] != 'override':
print(
"Error: %s's expansion is default but overrides %s"
% (selection['name'],
output_dict[selection_path]['name']))
sys.exit(1)
output_dict[selection_path] = copy.deepcopy(selection)
else:
print('Excluding selection:', selection_path)
if selection_path in output_dict:
if expansion_pattern['expansion'] != 'override':
print(
"Error: %s's expansion is default but overrides %s"
% (selection['name'],
output_dict[selection_path]['name']))
sys.exit(1)
output_dict[selection_path] = copy.deepcopy(selection)

for selection_path in output_dict:
selection = output_dict[selection_path]
if dump_test_parameters(selection) in exclusion_dict:
print('Excluding selection:', selection_path)
continue
try:
generate_selection(spec_directory, spec_json, selection, spec,
html_template)
@@ -1,6 +1,7 @@
from __future__ import print_function

import os, sys, json, re
import collections

script_directory = os.path.dirname(os.path.abspath(__file__))
template_directory = os.path.abspath(
@@ -30,7 +31,7 @@ def load_spec_json(path_to_spec):
re_error_location = re.compile('line ([0-9]+) column ([0-9]+)')
with open(path_to_spec, "r") as f:
try:
return json.load(f)
return json.load(f, object_pairs_hook=collections.OrderedDict)
except ValueError as ex:
print(ex.message)
match = re_error_location.search(ex.message)
@@ -47,7 +47,7 @@
// is to wait for some reasonable amount of time and if no report has been
// received to conclude that no report has been generated. These timeouts must
// not exceed the test timeouts set by vendors otherwise the test would fail.
var timeout = document.querySelector("meta[name=timeout][content=long]") ? 25 : 5;
var timeout = document.querySelector("meta[name=timeout][content=long]") ? 20 : 3;
var reportLocation = location.protocol + "//" + location.host + "/content-security-policy/support/report.py?op=retrieve_report&timeout=" + timeout + "&reportID=" + reportID;

if (testName == "") testName = "Violation report status OK.";
@@ -1,8 +1,7 @@
<!doctype html>
<html class="test-wait">
<title>CSS Animations Test: Chrome crash when removing documentElement and @keyframes stylesheet</title>
<link rel="help" href="https://crbug.com/999522">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<style>
@keyframes anim {
from { color: pink }
@@ -14,9 +13,16 @@
</style>
<div></div>
<script>
test(() => {
document.body.offsetTop;
document.querySelector("style").remove();
document.documentElement.remove();
}, "Removing documentElement and @keyframes sheet should not crash.");
window.addEventListener('load', () => {
document.body.offsetTop;
document.querySelector("style").remove();
// We need the root later to remove the test-wait class.
const root = document.documentElement;
document.documentElement.remove();

// rAF to make sure that style runs.
requestAnimationFrame(() => {
root.classList.remove('test-wait');
});
});
</script>
@@ -0,0 +1,83 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Pseudo-Elements Test: Computed size of ::marker</title>
<link rel="help" href="https://drafts.csswg.org/css-pseudo-4/#marker-pseudo">
<link rel="help" href="https://drafts.csswg.org/css-lists/#content-property">
<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com">
<meta name="assert" content="This test checks that getComputedStyle exposes the resolved sizes of a ::marker." />
<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
<style>
:root {
--image: url('/images/green-100x50.png');
}
:root::after {
/* Preload image */
content: var(--image);
}
#target {
font: 10px/1 Ahem;
--content: normal;
}
#target::marker {
content: var(--content);
}
</style>
<div id="log"></div>
<ul>
<li id="target"></li>
</ul>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
const target = document.getElementById("target");
function checkMarkerSize(expectedWidth, expectedHeight) {
const {width, height} = getComputedStyle(target, "::marker");
assert_equals(width, expectedWidth, "width");
assert_equals(height, expectedHeight, "height");
}
setup({explicit_done: true});
addEventListener("load", () => {
test(() => {
// Marker string: "1. "
target.style.listStyleType = "decimal";
checkMarkerSize("30px", "10px");
}, "Decimal ::marker");
test(() => {
// Marker string: "10. "
target.setAttribute("value", "10");
checkMarkerSize("40px", "10px");
}, "Decimal ::marker with custom value");
test(() => {
// Marker string: "st"
target.style.listStyleType = "'st'";
checkMarkerSize("20px", "10px");
}, "String ::marker");
test(() => {
// No marker box
target.style.listStyleType = "none";
checkMarkerSize("auto", "auto");
}, "::marker with no box due to 'list-style'");
test(() => {
// Marker contents: "foo", "bar"
target.style.setProperty("--content", "'foo' 'bar'");
checkMarkerSize("60px", "10px");
}, "::marker with custom string contents");
test(() => {
// Marker contents: 100x50 image (+2px due to baseline alignment)
target.style.setProperty("--content", "var(--image)");
checkMarkerSize("100px", "52px");
}, "::marker with custom image contents");
test(() => {
// Marker contents: "foo", 100x50 image (+2px due to baseline alignment)
target.style.setProperty("--content", "'foo' var(--image)");
checkMarkerSize("130px", "52px");
}, "::marker with custom string and image contents");
test(() => {
// No marker box
target.style.listStyleType = "";
target.style.setProperty("--content", "none");
checkMarkerSize("auto", "auto");
}, "::marker with no box due to 'content'");
done();
}, {once: true});
</script>
@@ -0,0 +1,29 @@
<!DOCTYPE html>
<html>
<head>
<title>CSS Shadow Parts - Serialization</title>
<link href="https://drafts.csswg.org/css-shadow-parts/" rel="help">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
</head>
<body>
<style id="styleElement">
::part(\(foo) {}
::part( bar\ ) {}
::part( -foo bar ) {}
</style>
<script>
"use strict";
const rules = styleElement.sheet.cssRules;
test(function() {
assert_equals(rules[0].selectorText, "::part(\\(foo)");
}, "Escape start parenthesis in ::part name.");
test(function() {
assert_equals(rules[1].selectorText, "::part(bar\\ )");
}, "Escape start space in ::part name.");
test(function() {
assert_equals(rules[2].selectorText, "::part(-foo bar)");
}, "Collapse spaces in ::part names list.");
</script>
</body>
</html>
@@ -70,6 +70,7 @@
test(function(){
assert_selector_serializes_to(':lang(ja)', ':lang(ja)');
assert_selector_serializes_to(':lang( ja )', ':lang(ja)');
assert_selector_serializes_to(':lang( j\\ a )', ':lang(j\\ a)');
}, 'single pseudo (simple) selector "lang" which accepts arguments in the sequence of simple selectors that is not a universal selector')


@@ -10,7 +10,7 @@
#test {
color: rgb(255, 0, 0);
}
span::-webkit-something-invalid, #test, ::-WeBkIt-sOmEtHiNg-NoNeXiSt123 {
span::-webkit-something-invalid, #test, ::-WeBkIt-sOmEtHiNg-NoNeXiSt123, ::-webkit-\ escaped {
color: rgb(0, 255, 0);
}
::-webkitfoo, #test {
@@ -29,7 +29,8 @@
let sheet = document.getElementById("style").sheet;
assert_equals(sheet.cssRules[1].selectorText,
"span::-webkit-something-invalid, " +
"#test, ::-webkit-something-nonexist123");
"#test, ::-webkit-something-nonexist123, " +
"::-webkit-\\ escaped");
}, "webkit-prefixed pseudo-element selectors should be accessible from CSSOM");

test(() => {
@@ -12,11 +12,10 @@ The simplest crashtest is a single HTML file with any content. The
test passes if the load event is reached, and the browser finishes
painting, without terminating.

In some cases crashtests may need to perform work after the initial
page load. In this case the test may specify a `class=wait` attribute
on the root element. The test will not complete until that attribute
is removed from the root. At the time when the test would otherwise
have ended a `TestRendered` event is emitted; test authors can use
this event to perform modifications that are guaranteed not to be
batched with the initial paint. This matches the behaviour of
[reftests](reftests).
In some cases crashtests may need to perform work after the initial page load.
In this case the test may specify a `class=test-wait` attribute on the root
element. The test will not complete until that attribute is removed from the
root. At the time when the test would otherwise have ended a `TestRendered`
event is emitted; test authors can use this event to perform modifications that
are guaranteed not to be batched with the initial paint. This matches the
behaviour of [reftests](reftests).
@@ -28,14 +28,13 @@
t.add_cleanup(() => { frame.remove(); });
const path = new URL("resources/blob-url-factory.html", window.location).pathname;
frame.src = `${origin}${path}?id=${id}&variant=${variant}&crossOrigin=${crossOrigin}`;
window.addEventListener("message", t.step_func(({ data }) => {
window.addEventListener("message", t.step_func_done(({ data }) => {
if (data.id !== id) {
return;
}
assert_equals(data.origin, origin);
assert_true(data.sameOriginNoCORPSuccess, "Same-origin without CORP did not succeed");
assert_true(data.crossOriginNoCORPFailure, "Cross-origin without CORP did not fail");
t.done();
}));
document.body.append(frame);
}, `Cross-Origin-Embedder-Policy and blob: URL from ${origin} in subframe via ${variant}`);
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.