mirror of
https://github.com/servo/servo.git
synced 2025-10-04 02:29:12 +01:00
Update web-platform-tests to revision 89ad54bd0d498c8209ec80407f5758566f91e82f
This commit is contained in:
parent
34bf312e0c
commit
1eb76da73c
27 changed files with 740 additions and 126 deletions
|
@ -28,14 +28,22 @@ function makeDeclaration(object = {}) {
|
|||
* element before starting the transition.
|
||||
* @param finalStyles A dictionary object with property names and values towards which
|
||||
* the element will transition.
|
||||
* @param [transitionStyles] An optional dictionary object to costumize the transition.
|
||||
*/
|
||||
function transition(t, baseStyles, finalStyles) {
|
||||
function transition(t, baseStyles, finalStyles, transitionStyles = {}) {
|
||||
// Clear styles from previous test.
|
||||
testEl.style.cssText = "";
|
||||
testEl.className = "";
|
||||
getComputedStyle(testEl).height;
|
||||
|
||||
// Set base styles
|
||||
// Set base and final styles
|
||||
addStyle(t, {
|
||||
"#test": makeDeclaration(baseStyles),
|
||||
"#test.transition": makeDeclaration(finalStyles),
|
||||
});
|
||||
getComputedStyle(testEl).height;
|
||||
|
||||
// Set transition styles
|
||||
const defaultTransition = {
|
||||
"transition-property": Object.keys(finalStyles).join(", "),
|
||||
"transition-timing-function": "linear",
|
||||
|
@ -43,10 +51,8 @@ function transition(t, baseStyles, finalStyles) {
|
|||
"transition-delay": "-5s",
|
||||
};
|
||||
addStyle(t, {
|
||||
"#test": makeDeclaration(Object.assign(defaultTransition, baseStyles)),
|
||||
"#test.transition": makeDeclaration(finalStyles),
|
||||
"#test": makeDeclaration(Object.assign(defaultTransition, transitionStyles)),
|
||||
});
|
||||
getComputedStyle(testEl).height;
|
||||
|
||||
// Start the transition
|
||||
testEl.className = "transition";
|
||||
|
@ -95,22 +101,22 @@ test(t => {
|
|||
}, 'Declaration order is respected within declaration blocks');
|
||||
|
||||
test(t => {
|
||||
transition(t, {
|
||||
"transition-timing-function": "step-start",
|
||||
}, {
|
||||
transition(t, {}, {
|
||||
"margin-top": "200px",
|
||||
"margin-block-start": "100px"
|
||||
}, {
|
||||
"transition-timing-function": "step-start",
|
||||
});
|
||||
assert_equals(getComputedStyle(testEl).marginTop, '100px');
|
||||
}, 'Logical properties are able to override physical properties in declaration blocks');
|
||||
|
||||
test(t => {
|
||||
transition(t, {
|
||||
"transition-timing-function": "step-start",
|
||||
}, {
|
||||
transition(t, {}, {
|
||||
"margin-inline": "200px",
|
||||
"margin-inline-start": "0px",
|
||||
"margin-inline-start": "100px",
|
||||
}, {
|
||||
"transition-timing-function": "step-start",
|
||||
});
|
||||
assert_equals(getComputedStyle(testEl).marginLeft, '100px');
|
||||
}, 'Declaration order is respected amongst logical properties within declaration blocks');
|
||||
|
@ -153,12 +159,13 @@ test(t => {
|
|||
|
||||
promise_test(async t => {
|
||||
transition(t, {
|
||||
"transition-delay": "-9.9s",
|
||||
"width": "0px",
|
||||
"height": "0px",
|
||||
"block-size": "0px",
|
||||
}, {
|
||||
"block-size": "100px",
|
||||
}, {
|
||||
"transition-delay": "-9.9s",
|
||||
});
|
||||
const watcher = new EventWatcher(t, testEl, [ 'transitionend' ]);
|
||||
await watcher.wait_for('transitionend');
|
||||
|
@ -247,4 +254,31 @@ test(t => {
|
|||
assert_equals(getComputedStyle(testEl).marginRight, '50px');
|
||||
}, 'Transitions update when the direction is changed');
|
||||
|
||||
test(t => {
|
||||
transition(t, {
|
||||
"margin-inline-start": "100px",
|
||||
}, {
|
||||
"margin-left": "200px",
|
||||
});
|
||||
assert_equals(getComputedStyle(testEl).marginLeft, '150px');
|
||||
assert_equals(getComputedStyle(testEl).marginRight, '0px');
|
||||
|
||||
testEl.style.direction = 'rtl';
|
||||
assert_equals(getComputedStyle(testEl).marginLeft, '150px');
|
||||
assert_equals(getComputedStyle(testEl).marginRight, '100px');
|
||||
}, 'Transitions from logical to physical update when the direction is changed');
|
||||
|
||||
test(t => {
|
||||
transition(t, {
|
||||
"margin-left": "200px",
|
||||
}, {
|
||||
"margin-inline-start": "100px",
|
||||
});
|
||||
assert_equals(getComputedStyle(testEl).marginLeft, '150px');
|
||||
assert_equals(getComputedStyle(testEl).marginRight, '0px');
|
||||
|
||||
testEl.style.direction = 'rtl';
|
||||
assert_equals(getComputedStyle(testEl).marginLeft, '200px');
|
||||
assert_equals(getComputedStyle(testEl).marginRight, '50px');
|
||||
}, 'Transitions from physical to logical update when the direction is changed');
|
||||
</script>
|
||||
|
|
|
@ -0,0 +1,48 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Multi-column Layout Test Reference: columns with list-item and column-span</title>
|
||||
<link rel="author" title="Ting-Yu Lin" href="tlin@mozilla.com">
|
||||
<link rel="author" title="Mozilla" href="http://www.mozilla.org/">
|
||||
|
||||
<style>
|
||||
li {
|
||||
width: 300px;
|
||||
outline: 1px solid black;
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
h3 {
|
||||
outline: 1px solid blue;
|
||||
margin: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<body>
|
||||
<ul>
|
||||
<li style="list-style-position: outside;">
|
||||
bullet outside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
bullet inside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<h3>spanner (bullet outside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<h3>spanner (bullet inside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet outside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet inside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,53 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Multi-column Layout Test: columns with list-item and column-span</title>
|
||||
<link rel="author" title="Ting-Yu Lin" href="tlin@mozilla.com">
|
||||
<link rel="author" title="Mozilla" href="http://www.mozilla.org/">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-multicol-1/#column-span">
|
||||
<link rel="match" href="multicol-span-all-list-item-001-ref.html">
|
||||
<meta name="assert" content="This test checks the columns with list-item are renederd correctly.">
|
||||
|
||||
<style>
|
||||
li {
|
||||
column-count: 1;
|
||||
width: 300px;
|
||||
outline: 1px solid black;
|
||||
margin-bottom: 1em;
|
||||
}
|
||||
h3 {
|
||||
column-span: all;
|
||||
outline: 1px solid blue;
|
||||
margin: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<body>
|
||||
<ul>
|
||||
<li style="list-style-position: outside;">
|
||||
bullet outside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
bullet inside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<h3>spanner (bullet outside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<h3>spanner (bullet inside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet outside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet inside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,49 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Multi-column Layout Test Reference: columns with list-item, column-span, and overflow</title>
|
||||
<link rel="author" title="Ting-Yu Lin" href="tlin@mozilla.com">
|
||||
<link rel="author" title="Mozilla" href="http://www.mozilla.org/">
|
||||
|
||||
<style>
|
||||
li {
|
||||
width: 300px;
|
||||
outline: 1px solid black;
|
||||
margin-bottom: 1em;
|
||||
overflow: hidden;
|
||||
}
|
||||
h3 {
|
||||
outline: 1px solid blue;
|
||||
margin: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<body>
|
||||
<ul>
|
||||
<li style="list-style-position: outside;">
|
||||
bullet outside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
bullet inside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<h3>spanner (bullet outside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<h3>spanner (bullet inside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet outside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet inside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,54 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Multi-column Layout Test: columns with list-item, column-span, and overflow</title>
|
||||
<link rel="author" title="Ting-Yu Lin" href="tlin@mozilla.com">
|
||||
<link rel="author" title="Mozilla" href="http://www.mozilla.org/">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-multicol-1/#column-span">
|
||||
<link rel="match" href="multicol-span-all-list-item-002-ref.html">
|
||||
<meta name="assert" content="This test checks the columns with list-item are renederd correctly.">
|
||||
|
||||
<style>
|
||||
li {
|
||||
column-count: 1;
|
||||
width: 300px;
|
||||
outline: 1px solid black;
|
||||
margin-bottom: 1em;
|
||||
overflow: hidden;
|
||||
}
|
||||
h3 {
|
||||
column-span: all;
|
||||
outline: 1px solid blue;
|
||||
margin: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<body>
|
||||
<ul>
|
||||
<li style="list-style-position: outside;">
|
||||
bullet outside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
bullet inside
|
||||
<h3>spanner</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<h3>spanner (bullet outside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<h3>spanner (bullet inside)</h3>
|
||||
</li>
|
||||
<li style="list-style-position: outside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet outside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
<li style="list-style-position: inside;">
|
||||
<div>
|
||||
<h3>nested spanner (bullet inside)</h3>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
|
@ -28,10 +28,12 @@
|
|||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<!-- XXX: This chunk needs to move to a separate test (Bug 1507663)
|
||||
<div class="flexBaselineCheck">
|
||||
outside before<div class="basic"></div>outside after
|
||||
</div>
|
||||
<br>
|
||||
-->
|
||||
|
||||
<div class="basic min col-width-ref"></div>
|
||||
<br>
|
||||
|
|
|
@ -38,10 +38,12 @@
|
|||
</head>
|
||||
<body>
|
||||
<!--CSS Test: A size-contained multicol element should perform baseline alignment as if it had no contents.-->
|
||||
<!-- XXX: This chunk needs to move to a separate test (Bug 1507663)
|
||||
<div class="flexBaselineCheck">
|
||||
outside before<div class="contain"><div class="innerContents">inner</div></div>outside after
|
||||
</div>
|
||||
<br>
|
||||
-->
|
||||
|
||||
<!--The following tests are used to ensure column-gaps and column-widths continue to contribute to the minimum and maximum width of a size-contained multicol element. Each should render as if it had no contents.-->
|
||||
|
||||
|
|
|
@ -15,18 +15,18 @@
|
|||
`${label} with BOM should decode as UTF-16LE`);
|
||||
|
||||
decode_test(label,
|
||||
'%41%00%00%00%42%00%00%00',
|
||||
'U+0041/U+0000/U+0000/U+0000/U+0042/U+0000/U+0000/U+0000',
|
||||
`${label} with no BOM should decode as windows-1252`);;
|
||||
'%41%00%00%00%42%00%00%C2%80',
|
||||
'U+0041/U+0000/U+0000/U+0000/U+0042/U+0000/U+0000/U+0080',
|
||||
`${label} with no BOM should decode as UTF-8`);;
|
||||
});
|
||||
['UTF-32be', 'utf-32be'].forEach(label => {
|
||||
decode_test(label,
|
||||
'%00%00%00%41%00%00%00%42',
|
||||
'U+0000/U+0000/U+0000/U+0041/U+0000/U+0000/U+0000/U+0042',
|
||||
`${label} with no BOM should decode as windows-1252`);
|
||||
'%00%00%00%41%00%00%00%42%C2%80',
|
||||
'U+0000/U+0000/U+0000/U+0041/U+0000/U+0000/U+0000/U+0042/U+0080',
|
||||
`${label} with no BOM should decode as UTF-8`);
|
||||
|
||||
decode_test(label,
|
||||
'%00%00%FE%FF%00%00%00%41%00%00%00%42',
|
||||
'U+0000/U+0000/U+00FE/U+00FF/U+0000/U+0000/U+0000/U+0041/U+0000/U+0000/U+0000/U+0042',
|
||||
`${label} with BOM should decode as windows-1252`);
|
||||
'%00%00%FE%FF%00%00%00%41%00%C2%80%42',
|
||||
'U+0000/U+0000/U+FFFD/U+FFFD/U+0000/U+0000/U+0000/U+0041/U+0000/U+0080/U+0042',
|
||||
`${label} with BOM should decode as UTF-8`);
|
||||
});
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:h="http://www.w3.org/1999/xhtml"
|
||||
width="800px" height="600px">
|
||||
<title>SVG Painting: parsing stroke-width with invalid values</title>
|
||||
<metadata>
|
||||
<h:link rel="help" href="https://svgwg.org/svg2-draft/painting.html#StrokeWidth"/>
|
||||
<h:meta name="assert" content="stroke-width supports only the grammar '<length-percentage>'."/>
|
||||
</metadata>
|
||||
<g id="target"></g>
|
||||
<h:script src="/resources/testharness.js"/>
|
||||
<h:script src="/resources/testharnessreport.js"/>
|
||||
<h:script src="/css/support/parsing-testcommon.js"/>
|
||||
<script><![CDATA[
|
||||
|
||||
test_invalid_value("stroke-width", "auto");
|
||||
test_invalid_value("stroke-width", "10px 20px");
|
||||
test_invalid_value("stroke-width", "-1px");
|
||||
test_invalid_value("stroke-width", "-10%");
|
||||
|
||||
]]></script>
|
||||
</svg>
|
After Width: | Height: | Size: 850 B |
|
@ -0,0 +1,24 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:h="http://www.w3.org/1999/xhtml"
|
||||
width="800px" height="600px">
|
||||
<title>SVG Painting: parsing stroke-width with valid values</title>
|
||||
<metadata>
|
||||
<h:link rel="help" href="https://svgwg.org/svg2-draft/painting.html#StrokeWidth"/>
|
||||
<h:meta name="assert" content="stroke-width supports the full grammar '<length-percentage>' and unitless."/>
|
||||
</metadata>
|
||||
<g id="target"></g>
|
||||
<h:script src="/resources/testharness.js"/>
|
||||
<h:script src="/resources/testharnessreport.js"/>
|
||||
<h:script src="/css/support/parsing-testcommon.js"/>
|
||||
<script><![CDATA[
|
||||
|
||||
test_valid_value("stroke-width", "0");
|
||||
test_valid_value("stroke-width", "10");
|
||||
test_valid_value("stroke-width", "1px");
|
||||
test_valid_value("stroke-width", "calc(2em + 3ex)");
|
||||
test_valid_value("stroke-width", "4%");
|
||||
test_valid_value("stroke-width", "5vmin");
|
||||
|
||||
]]></script>
|
||||
</svg>
|
After Width: | Height: | Size: 936 B |
5
tests/wpt/web-platform-tests/webrtc-quic/META.yml
Normal file
5
tests/wpt/web-platform-tests/webrtc-quic/META.yml
Normal file
|
@ -0,0 +1,5 @@
|
|||
spec: https://github.com/w3c/webrtc-quic
|
||||
suggested_reviewers:
|
||||
- aboba
|
||||
- henbos
|
||||
- steveanton
|
|
@ -3,7 +3,7 @@
|
|||
<title>RTCQuicStream.https.html</title>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="RTCIceTransport-extension-helper.js"></script>
|
||||
<script src="../webrtc/RTCIceTransport-extension-helper.js"></script>
|
||||
<script src="RTCQuicTransport-helper.js"></script>
|
||||
<script src="RTCQuicStream-helper.js"></script>
|
||||
<script>
|
|
@ -3,7 +3,7 @@
|
|||
<title>RTCQuicTransport.https.html</title>
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="RTCIceTransport-extension-helper.js"></script>
|
||||
<script src="../webrtc/RTCIceTransport-extension-helper.js"></script>
|
||||
<script src="RTCQuicTransport-helper.js"></script>
|
||||
<script>
|
||||
'use strict';
|
Loading…
Add table
Add a link
Reference in a new issue