diff options
author | WPT Sync Bot <josh+wptsync@joshmatthews.net> | 2020-04-21 08:21:40 +0000 |
---|---|---|
committer | WPT Sync Bot <josh+wptsync@joshmatthews.net> | 2020-04-21 11:23:54 +0000 |
commit | 906e45aab01239d9393fa09d68a783e543fae1dc (patch) | |
tree | 9615730f707c85e4f0d75867941ff4a810797d3e | |
parent | d77bf218fafe84dc0eb8c2f148e27e906ac3e8c7 (diff) | |
download | servo-906e45aab01239d9393fa09d68a783e543fae1dc.tar.gz servo-906e45aab01239d9393fa09d68a783e543fae1dc.zip |
Update web-platform-tests to revision 9a6026305062c90d84a567d81434010dde6c6c22
210 files changed, 6025 insertions, 380 deletions
diff --git a/tests/wpt/metadata-layout-2020/2dcontext/2d.filter.value.html.ini b/tests/wpt/metadata-layout-2020/2dcontext/2d.filter.value.html.ini new file mode 100644 index 00000000000..c64d43962d9 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/2dcontext/2d.filter.value.html.ini @@ -0,0 +1,4 @@ +[2d.filter.value.html] + [test if ctx.filter works correctly] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/css/CSS2/floats/hit-test-floats-004.html.ini b/tests/wpt/metadata-layout-2020/css/CSS2/floats/hit-test-floats-003.html.ini index 4bfb0c2053a..f29da48a2a0 100644 --- a/tests/wpt/metadata-layout-2020/css/CSS2/floats/hit-test-floats-004.html.ini +++ b/tests/wpt/metadata-layout-2020/css/CSS2/floats/hit-test-floats-003.html.ini @@ -1,4 +1,4 @@ -[hit-test-floats-004.html] +[hit-test-floats-003.html] [Miss float below something else] expected: FAIL diff --git a/tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPosition.html.ini b/tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPosition.html.ini index c131078eace..23c61ede1a1 100644 --- a/tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPosition.html.ini +++ b/tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPosition.html.ini @@ -17,3 +17,6 @@ [test the top of layer] expected: FAIL + [test some point of the element: top left corner] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/css/cssom-view/elementsFromPoint-iframes.html.ini b/tests/wpt/metadata-layout-2020/css/cssom-view/elementsFromPoint-iframes.html.ini index 171592fc08f..6ef8bb1049f 100644 --- a/tests/wpt/metadata-layout-2020/css/cssom-view/elementsFromPoint-iframes.html.ini +++ b/tests/wpt/metadata-layout-2020/css/cssom-view/elementsFromPoint-iframes.html.ini @@ -2,3 +2,6 @@ [elementsFromPoint on the root document for points in iframe elements] expected: FAIL + [elementsFromPoint on inner documents] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/custom-elements/customized-built-in-constructor-exceptions.html.ini b/tests/wpt/metadata-layout-2020/custom-elements/customized-built-in-constructor-exceptions.html.ini new file mode 100644 index 00000000000..10c7e55eab6 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/custom-elements/customized-built-in-constructor-exceptions.html.ini @@ -0,0 +1,2 @@ +[customized-built-in-constructor-exceptions.html] + expected: CRASH diff --git a/tests/wpt/metadata-layout-2020/dom/nodes/ParentNode-replaceChildren.html.ini b/tests/wpt/metadata-layout-2020/dom/nodes/ParentNode-replaceChildren.html.ini new file mode 100644 index 00000000000..ae9d14fd80b --- /dev/null +++ b/tests/wpt/metadata-layout-2020/dom/nodes/ParentNode-replaceChildren.html.ini @@ -0,0 +1,76 @@ +[ParentNode-replaceChildren.html] + [DocumentFragment.replaceChildren() with null as an argument, on a parent having a child.] + expected: FAIL + + [DocumentFragment.replaceChildren() with only text as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() with null as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() without any argument, on a parent having no child.] + expected: FAIL + + [If node is a host-including inclusive ancestor of parent, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is an Element and parent is a document with another element, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [DocumentFragment.replaceChildren() with null as an argument, on a parent having no child.] + expected: FAIL + + [DocumentFragment.replaceChildren() with one element and text as argument, on a parent having a child.] + expected: FAIL + + [Element.replaceChildren() with null as an argument, on a parent having a child.] + expected: FAIL + + [DocumentFragment.replaceChildren() with only one element as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() should move nodes in the right order] + expected: FAIL + + [If node is a Text node and parent is a document, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is a DocumentFragment with an element and parent is a document with another element, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [DocumentFragment.replaceChildren() with undefined as an argument, on a parent having no child.] + expected: FAIL + + [If node is a doctype and parent is not a document, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is a doctype and parent is a document with another doctype, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is a DocumentFragment with multiple elements and parent is a document, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [Element.replaceChildren() with undefined as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() with only one element as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() with one element and text as argument, on a parent having a child.] + expected: FAIL + + [DocumentFragment.replaceChildren() should move nodes in the right order] + expected: FAIL + + [If node is a doctype and parent is a document with an element, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [Element.replaceChildren() with only text as an argument, on a parent having no child.] + expected: FAIL + + [DocumentFragment.replaceChildren() without any argument, on a parent having no child.] + expected: FAIL + + [If node is not a DocumentFragment, DocumentType, Element, Text, ProcessingInstruction, or Comment node, then throw a HierarchyRequestError DOMException.] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/fetch/content-type/response.window.js.ini b/tests/wpt/metadata-layout-2020/fetch/content-type/response.window.js.ini index ae125a215ca..867aa1150a7 100644 --- a/tests/wpt/metadata-layout-2020/fetch/content-type/response.window.js.ini +++ b/tests/wpt/metadata-layout-2020/fetch/content-type/response.window.js.ini @@ -315,18 +315,21 @@ [<iframe>: combined response Content-Type: text/html;" \\" text/plain] expected: FAIL - [<iframe>: separate response Content-Type: text/html */*;charset=gbk] + [<iframe>: separate response Content-Type: text/plain */*] expected: FAIL - [<iframe>: separate response Content-Type: text/plain */*] + [<iframe>: combined response Content-Type: text/html;" text/plain] + expected: FAIL + + [<iframe>: combined response Content-Type: */* text/html] expected: FAIL - [<iframe>: combined response Content-Type: text/html */*;charset=gbk] + [<iframe>: combined response Content-Type: text/html;charset=gbk text/plain text/html] expected: FAIL - [<iframe>: separate response Content-Type: text/html;" \\" text/plain] + [<iframe>: separate response Content-Type: text/html;" text/plain] expected: FAIL - [<iframe>: separate response Content-Type: text/plain */*;charset=gbk] + [<iframe>: separate response Content-Type: text/html;x=" text/plain] expected: FAIL diff --git a/tests/wpt/metadata-layout-2020/fetch/content-type/script.window.js.ini b/tests/wpt/metadata-layout-2020/fetch/content-type/script.window.js.ini index 2d5faa72ac7..9c6c5193b99 100644 --- a/tests/wpt/metadata-layout-2020/fetch/content-type/script.window.js.ini +++ b/tests/wpt/metadata-layout-2020/fetch/content-type/script.window.js.ini @@ -56,3 +56,9 @@ [separate text/javascript;charset=windows-1252 error text/javascript] expected: FAIL + [separate text/javascript x/x] + expected: FAIL + + [separate text/javascript; charset=windows-1252 text/javascript] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/fetch/nosniff/parsing-nosniff.window.js.ini b/tests/wpt/metadata-layout-2020/fetch/nosniff/parsing-nosniff.window.js.ini index 2023a855086..87c807a49ff 100644 --- a/tests/wpt/metadata-layout-2020/fetch/nosniff/parsing-nosniff.window.js.ini +++ b/tests/wpt/metadata-layout-2020/fetch/nosniff/parsing-nosniff.window.js.ini @@ -11,6 +11,3 @@ [X-Content-Type-Options%3A%20nosniff%0C] expected: FAIL - [X-Content-Type-Options%3A%20no%0D%0AX-Content-Type-Options%3A%20nosniff] - expected: FAIL - diff --git a/tests/wpt/metadata-layout-2020/html/browsers/history/the-history-interface/traverse_the_history_4.html.ini b/tests/wpt/metadata-layout-2020/html/browsers/history/the-history-interface/traverse_the_history_4.html.ini new file mode 100644 index 00000000000..385376c7321 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/html/browsers/history/the-history-interface/traverse_the_history_4.html.ini @@ -0,0 +1,4 @@ +[traverse_the_history_4.html] + [Multiple history traversals, last would be aborted] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini b/tests/wpt/metadata-layout-2020/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini index 8140ed890b2..ac3a4dabbb2 100644 --- a/tests/wpt/metadata-layout-2020/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini +++ b/tests/wpt/metadata-layout-2020/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini @@ -17,9 +17,6 @@ [Set data URL frame location.protocol to data] expected: FAIL - [Set data URL frame location.protocol to file] - expected: FAIL - [Set data URL frame location.protocol to http+x] expected: FAIL diff --git a/tests/wpt/metadata-layout-2020/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini b/tests/wpt/metadata-layout-2020/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini index 4e69eb752b6..f45aaafe1c5 100644 --- a/tests/wpt/metadata-layout-2020/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini +++ b/tests/wpt/metadata-layout-2020/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini @@ -1,16 +1,15 @@ [supported-elements.html] - expected: TIMEOUT [Contenteditable element should support autofocus] expected: FAIL [Host element with delegatesFocus including no focusable descendants should be skipped] - expected: TIMEOUT + expected: FAIL [Element with tabindex should support autofocus] expected: FAIL [Area element should support autofocus] - expected: NOTRUN + expected: FAIL [Host element with delegatesFocus should support autofocus] expected: FAIL diff --git a/tests/wpt/metadata-layout-2020/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini b/tests/wpt/metadata-layout-2020/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini index 0fbc49ea1c1..7a36937927c 100644 --- a/tests/wpt/metadata-layout-2020/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini +++ b/tests/wpt/metadata-layout-2020/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini @@ -1,5 +1,4 @@ [iframe_sandbox_popups_nonescaping-3.html] - expected: CRASH [Check that popups from a sandboxed iframe do not escape the sandbox] - expected: NOTRUN + expected: FAIL diff --git a/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html.ini b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html.ini new file mode 100644 index 00000000000..59a54fe88e4 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html.ini @@ -0,0 +1,4 @@ +[module-delayed.html] + [async document.write in a module] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html.ini b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html.ini new file mode 100644 index 00000000000..30c8d2fd9d5 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html.ini @@ -0,0 +1,5 @@ +[module-dynamic-import.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html.ini b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html.ini new file mode 100644 index 00000000000..6527fa02f03 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html.ini @@ -0,0 +1,5 @@ +[module-tla-delayed.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html.ini b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html.ini new file mode 100644 index 00000000000..1300a9536d6 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html.ini @@ -0,0 +1,5 @@ +[module-tla-immediate-promise.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html.ini b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html.ini new file mode 100644 index 00000000000..30d23c291f1 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html.ini @@ -0,0 +1,4 @@ +[module-tla-import.html] + [document.write in an imported module] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html.ini b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html.ini new file mode 100644 index 00000000000..8694e58234a --- /dev/null +++ b/tests/wpt/metadata-layout-2020/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html.ini @@ -0,0 +1,5 @@ +[module-tla-promise.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata-layout-2020/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini b/tests/wpt/metadata-layout-2020/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini index 5602ea31dbe..450c88bd32b 100644 --- a/tests/wpt/metadata-layout-2020/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini +++ b/tests/wpt/metadata-layout-2020/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini @@ -4,5 +4,5 @@ expected: TIMEOUT [The entry settings object while executing the compiled callback via Web IDL's invoke must be that of the node document] - expected: TIMEOUT + expected: FAIL diff --git a/tests/wpt/metadata-layout-2020/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini b/tests/wpt/metadata-layout-2020/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini index 73d24ae66f4..a74bf0d53a7 100644 --- a/tests/wpt/metadata-layout-2020/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini +++ b/tests/wpt/metadata-layout-2020/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini @@ -92,3 +92,6 @@ [X Rendered audio for channel 5 does not equal [0,0.0626220703125,0.125030517578125,0.18695068359375,0.24810791015625,0.308319091796875,0.3673095703125,0.42486572265625,0.480743408203125,0.53472900390625,0.58660888671875,0.636199951171875,0.68328857421875,0.727691650390625,0.76922607421875,0.8077392578125...\] with an element-wise tolerance of {"absoluteThreshold":0.000030517578125,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[1\]\t3.6732959747314453e-1\t6.2622070312500000e-2\t3.0470752716064453e-1\t4.8658168859649127e+0\t3.0517578125000000e-5\n\t[2\]\t6.8329977989196777e-1\t1.2503051757812500e-1\t5.5826926231384277e-1\t4.4650639949963384e+0\t3.0517578125000000e-5\n\t[3\]\t9.0373212099075317e-1\t1.8695068359375000e-1\t7.1678143739700317e-1\t3.8340669508039502e+0\t3.0517578125000000e-5\n\t[4\]\t9.9780619144439697e-1\t2.4810791015625000e-1\t7.4969828128814697e-1\t3.0216621502152523e+0\t3.0517578125000000e-5\n\t[5\]\t9.5236867666244507e-1\t3.0831909179687500e-1\t6.4404958486557007e-1\t2.0889059484187866e+0\t3.0517578125000000e-5\n\t...and 44050 more errors.\n\tMax AbsError of 1.9986916780471802e+0 at index of 42250.\n\t[42250\]\t9.9994289875030518e-1\t-9.9874877929687500e-1\t1.9986916780471802e+0\t2.0011956154322119e+0\t3.0517578125000000e-5\n\tMax RelError of Infinity at index of 14112.\n\t[14112\]\t-9.5105654001235962e-1\t0.0000000000000000e+0\t9.5105654001235962e-1\tInfinity\t3.0517578125000000e-5\n] expected: FAIL + [X Rendered audio for channel 5 does not equal [0,0.0626220703125,0.125030517578125,0.18695068359375,0.24810791015625,0.308319091796875,0.3673095703125,0.42486572265625,0.480743408203125,0.53472900390625,0.58660888671875,0.636199951171875,0.68328857421875,0.727691650390625,0.76922607421875,0.8077392578125...\] with an element-wise tolerance of {"absoluteThreshold":0.000030517578125,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[1\]\t3.6732959747314453e-1\t6.2622070312500000e-2\t3.0470752716064453e-1\t4.8658168859649127e+0\t3.0517578125000000e-5\n\t[2\]\t6.8329977989196777e-1\t1.2503051757812500e-1\t5.5826926231384277e-1\t4.4650639949963384e+0\t3.0517578125000000e-5\n\t[3\]\t9.0373212099075317e-1\t1.8695068359375000e-1\t7.1678143739700317e-1\t3.8340669508039502e+0\t3.0517578125000000e-5\n\t[4\]\t9.9780619144439697e-1\t2.4810791015625000e-1\t7.4969828128814697e-1\t3.0216621502152523e+0\t3.0517578125000000e-5\n\t[5\]\t9.5236867666244507e-1\t3.0831909179687500e-1\t6.4404958486557007e-1\t2.0889059484187866e+0\t3.0517578125000000e-5\n\t...and 42283 more errors.\n\tMax AbsError of 1.9962286949157715e+0 at index of 36587.\n\t[36587\]\t9.9879217147827148e-1\t-9.9743652343750000e-1\t1.9962286949157715e+0\t2.0013591321441684e+0\t3.0517578125000000e-5\n\tMax RelError of Infinity at index of 15876.\n\t[15876\]\t5.8778524398803711e-1\t0.0000000000000000e+0\t5.8778524398803711e-1\tInfinity\t3.0517578125000000e-5\n] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/webmessaging/with-ports/018.html.ini b/tests/wpt/metadata-layout-2020/webmessaging/with-ports/018.html.ini new file mode 100644 index 00000000000..663a1f8fa30 --- /dev/null +++ b/tests/wpt/metadata-layout-2020/webmessaging/with-ports/018.html.ini @@ -0,0 +1,5 @@ +[018.html] + expected: TIMEOUT + [origin of the script that invoked the method, javascript:] + expected: TIMEOUT + diff --git a/tests/wpt/metadata/2dcontext/2d.filter.value.html.ini b/tests/wpt/metadata/2dcontext/2d.filter.value.html.ini new file mode 100644 index 00000000000..c64d43962d9 --- /dev/null +++ b/tests/wpt/metadata/2dcontext/2d.filter.value.html.ini @@ -0,0 +1,4 @@ +[2d.filter.value.html] + [test if ctx.filter works correctly] + expected: FAIL + diff --git a/tests/wpt/metadata/MANIFEST.json b/tests/wpt/metadata/MANIFEST.json index fe3c8c39771..57b9a787bda 100644 --- a/tests/wpt/metadata/MANIFEST.json +++ b/tests/wpt/metadata/MANIFEST.json @@ -61,6 +61,13 @@ ] }, "css-flexbox": { + "fixedpos-video-in-abspos-quirk-crash.html": [ + "80cae086ca7ba1ceb9af2631ea2a5aa04249040b", + [ + null, + {} + ] + ], "flex-shrink-large-value-crash.html": [ "a48bec65581e9f350a74d2b7b937df8fbe9113d5", [ @@ -141592,6 +141599,110 @@ ] ], "self-baseline": { + "grid-self-baseline-001.html": [ + "2473bb5d4fc8adc351af441bf39cffcacc076273", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-001-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-002-b.html": [ + "7d9ebecb8ca542f8ebb7574e87a77c086262ebca", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-002-b-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-002.html": [ + "700fd26097e850a3a348dedc657ebd295a439486", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-002-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-003.html": [ + "2372ac19318f65ba1a28ff15aea46579d10c63aa", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-003-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-004.html": [ + "c7f49bf24af08f82df9d2975bd485057de5e3018", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-004-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-005.html": [ + "3bfa2d2079955095fc73244f7073e99aeda0e5b1", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-005-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-006.html": [ + "34edced2b4345474acd364f6d3cb6310f24eca3e", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-006-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-007.html": [ + "e0966bb6e6421a5e950d486e3f45b93ce4a55416", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-007-ref.html", + "==" + ] + ], + {} + ] + ], "grid-self-baseline-changes-grid-area-size-001.html": [ "5b2ecaaab06b1f86397818fe5522cbc1e0a2f55a", [ @@ -141747,6 +141858,279 @@ ], {} ] + ], + "grid-self-baseline-horiz-001.html": [ + "556009dfde719b49ad0bb62f939e4a08ee16053f", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-001-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-horiz-002.html": [ + "c196cd35c514da0e35a6754a3e7905b02d6eda16", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-002-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-horiz-003.html": [ + "287cb80fd58b4f8feb57ce5723478cb025c77040", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-003-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-horiz-004.html": [ + "673c9ff20829c5ac451443bf9bccacb6ed9d6546", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-004-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-horiz-005.html": [ + "f816e893ca288abeb0b94a13d049f04d6ea8b4f4", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-005-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-horiz-006.html": [ + "c034040b5fdc032770014d4b55ef55c2f5b7956c", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-006-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-horiz-007.html": [ + "60185142427a8858a37c93e380578a37cd9b936d", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-007-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-lr-001.html": [ + "801474df57c29737a173e46c0eb59a5e4211f0ed", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-001-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-lr-002.html": [ + "6dd235a7b6fcdf7a7d37ee5f65776e28669bf252", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-002-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-lr-003.html": [ + "18f581620d611e159f9c9af8f9a9bc4b40b3a3ae", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-003-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-lr-004.html": [ + "1f2e3860b06f96a5d4fe1ee6416a9ba78f347eee", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-004-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-lr-005.html": [ + "a27cb67898eb5e3167c6869faffaf2936e9705cd", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-005-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-lr-006.html": [ + "654c17cd9e85ba7bb3d2abdd91e5405036d6ddaa", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-006-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-lr-007.html": [ + "ae7b6bf36ea49eb8b078a5b40f608dc8a7167323", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-007-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-rl-001.html": [ + "af7ca16d6345ad52c00d2efcc5bd33fca93d5619", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-001-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-rl-002.html": [ + "9aa00a71147d2c4618859ba28905ddf6f0c4cd9a", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-002-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-rl-003.html": [ + "2ae2f4fba6536359b8ec11b71f3b448445e776a2", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-003-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-rl-004.html": [ + "d2f08642fcd52bbb574206b957caf1a71cec231c", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-004-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-rl-005.html": [ + "0d40ce288d7406bec157fb27aff9bcb591d3b87d", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-005-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-rl-006.html": [ + "40f1e0796ea3733d55679a3aa5fcbe8a220ab4bc", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-006-ref.html", + "==" + ] + ], + {} + ] + ], + "grid-self-baseline-vertical-rl-007.html": [ + "49bab61ca091aaab8e4773d29ea274ba3be3790c", + [ + null, + [ + [ + "/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-007-ref.html", + "==" + ] + ], + {} + ] ] } }, @@ -143798,6 +144182,19 @@ {} ] ], + "grid-container-scrollbars-sizing-002.html": [ + "99cc5ee771d32047586268a4fbc7e9b6e3e22277", + [ + null, + [ + [ + "/css/css-grid/reference/grid-container-scrollbars-sizing-002-ref.html", + "==" + ] + ], + {} + ] + ], "grid-display-grid-001.html": [ "3599aa960416f07ed63734b8ff959d997f74d1b9", [ @@ -174451,6 +174848,19 @@ {} ] ], + "trailing-space-rtl-001.html": [ + "8bc6cc75cbeaf8b6a091b2aadd5eead52d3b1bfd", + [ + null, + [ + [ + "/css/css-text/white-space/reference/trailing-space-rtl-001-ref.html", + "==" + ] + ], + {} + ] + ], "white-space-empty-text-sibling.html": [ "50439df433cea8d4191989cb3d5444ff9f8d15c1", [ @@ -240988,10 +241398,6 @@ [] ] }, - "green-100x50.png": [ - "2733836c998fa919d9f6880fd96a32026e82ca2c", - [] - ], "imagebitmap": { "common.sub.js": [ "aa1e382a2088fee541a1020a03a4299a3b18d6cd", @@ -241174,7 +241580,7 @@ [] ], "tests2d.yaml": [ - "d8ccbe13f6dbb3edf891c9e507dbf6449ec942af", + "9dad482562ba77849a75b464558e3f5e44647f04", [] ], "tests2dtext.yaml": [ @@ -263703,7 +264109,7 @@ "dc5f30a03a36f880aac5aa2c2b3e2acb736470cc", [] ], - "script-src-strict_dynamic_discard_whitelist.html.headers": [ + "script-src-strict_dynamic_discard_source_expressions.html.headers": [ "8499eb0559d7f975a1c9114661b828cf79507e18", [] ], @@ -263711,7 +264117,7 @@ "63d96aaf1ee7d55a1ae74bc697c3686467fb85d0", [] ], - "script-src-strict_dynamic_double_policy_honor_whitelist.sub.html.headers": [ + "script-src-strict_dynamic_double_policy_honor_source_expressions.html.headers": [ "5b4078efd377ffdf3db5346a2ae07cdb971e854f", [] ], @@ -295028,6 +295434,124 @@ [] ] }, + "self-baseline": { + "grid-self-baseline-001-ref.html": [ + "c85fd77ef91092a1e87a9a60ddf5bc5392b3be3b", + [] + ], + "grid-self-baseline-002-b-ref.html": [ + "460a4537eb71c60983b798d4ba23ff3f728c19ce", + [] + ], + "grid-self-baseline-002-ref.html": [ + "9c2f6e45218962edc0839401ddc6abf9a7998023", + [] + ], + "grid-self-baseline-003-ref.html": [ + "cd097c1d48a6ba4cddf10030e2d499c383ac2fed", + [] + ], + "grid-self-baseline-004-ref.html": [ + "d589acb3742cdc8cd61557d5a5afa9d1cf206b2f", + [] + ], + "grid-self-baseline-005-ref.html": [ + "75a366fc409d7ecc19fef2408b0aad08a302b778", + [] + ], + "grid-self-baseline-006-ref.html": [ + "610b2ad0a11ff010e30fc9c8d8a532c5e8c7c973", + [] + ], + "grid-self-baseline-007-ref.html": [ + "59a0e339598b4c6e0f9b604636c9199826c45f2d", + [] + ], + "grid-self-baseline-horiz-001-ref.html": [ + "1b8130d7b89ae35111009318535320e05bbda766", + [] + ], + "grid-self-baseline-horiz-002-ref.html": [ + "a99656f94e2f3947dc9e2d1e8d479f534d661ecf", + [] + ], + "grid-self-baseline-horiz-003-ref.html": [ + "58f68d5b258398158d7e47b1cfa6e5c271f4bbe7", + [] + ], + "grid-self-baseline-horiz-004-ref.html": [ + "be610d4f7f2ba9a0fd51116e3dfd66be89c470af", + [] + ], + "grid-self-baseline-horiz-005-ref.html": [ + "5e2f6da9d5f475dff69f2b6763d042570a9273e7", + [] + ], + "grid-self-baseline-horiz-006-ref.html": [ + "6053b38a6fdf1e402ed341d2077dd3b2e78cc990", + [] + ], + "grid-self-baseline-horiz-007-ref.html": [ + "e92a90ef26941dc82e72484db2706e793c1c3f63", + [] + ], + "grid-self-baseline-vertical-lr-001-ref.html": [ + "cf19544be84333c3820a8cb7776d019ea3c15693", + [] + ], + "grid-self-baseline-vertical-lr-002-ref.html": [ + "1aef905f16bc8041814603ca31cd3c362e8cda04", + [] + ], + "grid-self-baseline-vertical-lr-003-ref.html": [ + "795926615fabb0634162ae2592eae10d4450a4f6", + [] + ], + "grid-self-baseline-vertical-lr-004-ref.html": [ + "cd6569ffbfd6851d7494f3c1af141429905a056d", + [] + ], + "grid-self-baseline-vertical-lr-005-ref.html": [ + "571a77d3431bb52be8b7b140eafa2ecb89cd1d1d", + [] + ], + "grid-self-baseline-vertical-lr-006-ref.html": [ + "51c5f77da3574f49b5d9ce87d1f3128607f07f9d", + [] + ], + "grid-self-baseline-vertical-lr-007-ref.html": [ + "fe00a5f5a2eb74848e9af20b2cba80fe29526ef6", + [] + ], + "grid-self-baseline-vertical-rl-001-ref.html": [ + "02d3feb12672028ba0616414b93245327014807f", + [] + ], + "grid-self-baseline-vertical-rl-002-ref.html": [ + "3be7c42ee5dabe379621b57a3b27a90a717c1021", + [] + ], + "grid-self-baseline-vertical-rl-003-ref.html": [ + "03307a601de91b703b6a564e962e712add6e0f11", + [] + ], + "grid-self-baseline-vertical-rl-004-ref.html": [ + "2e3e032ac8ca7430a7de88d78ecd44afcd60f8bb", + [] + ], + "grid-self-baseline-vertical-rl-005-ref.html": [ + "067129b8dc9afdac338df0d00798fa8782240a08", + [] + ], + "grid-self-baseline-vertical-rl-006-ref.html": [ + "4011c691427b8f13ac15f79409213df39a82b86c", + [] + ], + "grid-self-baseline-vertical-rl-007-ref.html": [ + "ffa3e0512a90d436669c41a64bbaf561046dd079", + [] + ] + }, "support": { "100x100-green.png": [ "25b76c3c6f216793a36b1f29287dafd993898c67", @@ -295294,6 +295818,10 @@ "a090f7955907bd1819b22d54b8cb0bf966d93e0a", [] ], + "grid-container-scrollbars-sizing-002-ref.html": [ + "d77d7f8066a345dbeecfb85820b1871c5aff9104", + [] + ], "grid-different-gutters-ref.html": [ "57d27ff3aaea88eaeeed6f34f8ac49623b409fd2", [] @@ -302375,6 +302903,10 @@ "b65a8fe75479c0119a8ecc156b9a5d5f318d66d0", [] ], + "trailing-space-rtl-001-ref.html": [ + "f3f25235911e7a317377a57d66d68318aaf2eaf6", + [] + ], "white-space-break-spaces-005-ref.html": [ "dece5f7394470d5bbc393c4318fa412ea25f9b4e", [] @@ -315019,7 +315551,11 @@ "a95529ab39cdcbc19c627d1b1dc998ac426c5e9b", [] ], - "pre-insertion-checks.js": [ + "pre-insertion-validation-hierarchy.js": [ + "6ef2576df2c70bf6d13509c92071541c8e5bb5c7", + [] + ], + "pre-insertion-validation-notfound.js": [ "705283fa235093eb4be4251b265729412679baf8", [] ], @@ -328565,8 +329101,56 @@ "bf038f70049ae6f2ca152ba09ae10377a4d7dea7", [] ], + "module-delayed-iframe.html": [ + "f97f597238e2a461273e2f10e1eaae0cac2114a6", + [] + ], + "module-dynamic-import-iframe.html": [ + "672bb953d6cc27940c6e09cc5a0f9f31e000c7f7", + [] + ], + "module-dynamic-import.mjs": [ + "74d242753706c09739d03e3bc8e9c7f33657e8a2", + [] + ], "module-iframe.html": [ - "997d1eb1a34267002afeb26ff8548f2eb15cffdf", + "f8646df56b77279bbae20df38e251d49201038f5", + [] + ], + "module-static-import-delayed-iframe.html": [ + "3ae1464653afd8fc519e198a63167c7f561a4123", + [] + ], + "module-static-import-delayed.mjs": [ + "45478d6f638afd4621f540d6b0861df045707fed", + [] + ], + "module-static-import-iframe.html": [ + "ed4f6d1c6c972107c185662618447838879bbf36", + [] + ], + "module-static-import.mjs": [ + "74d242753706c09739d03e3bc8e9c7f33657e8a2", + [] + ], + "module-tla-delayed-iframe.html": [ + "684113616574f1e13c7e58a1abafa2b97a18de6d", + [] + ], + "module-tla-immediate-promise-iframe.html": [ + "3e90fb2ea73d34e0a0b542f30ef738b94458c517", + [] + ], + "module-tla-import-iframe.html": [ + "ec4a6ed6aa2317a24d50d7a066c26dfa0e1e324e", + [] + ], + "module-tla-import.mjs": [ + "74d242753706c09739d03e3bc8e9c7f33657e8a2", + [] + ], + "module-tla-promise-iframe.html": [ + "5c55bed6c07af592f14ad2372722d3388a5041a6", [] ], "nested-document-write-1.html": [ @@ -329075,7 +329659,7 @@ [] ], "green-100x50.png": [ - "2b7577d2689913b759e1f3a33d8880788622882d", + "2733836c998fa919d9f6880fd96a32026e82ca2c", [] ], "green-16x16.png": [ @@ -330020,6 +330604,10 @@ "3754fd81e6bf605a308794e5b759ecd8784a6a15", [] ], + "hit-test.idl": [ + "0da492883b6d74fd5b94b7600dfd54047adac679", + [] + ], "hr-time.idl": [ "8179c66f44de27acf4d099ec2a213f7623cbcd6b", [] @@ -330136,6 +330724,10 @@ "e48e0632bd89ff764fa9b3864207b39723a388cf", [] ], + "page-lifecycle.idl": [ + "f3d9c1f3f5647539aa840650befb26e76812083d", + [] + ], "page-visibility.idl": [ "6b8bd52a047ce411b968a79e6d0f7d152ab32a57", [] @@ -330177,7 +330769,7 @@ [] ], "pointerevents.idl": [ - "f4405438632be3cad59ee52c7c62bca630df875f", + "728fff98d919cc8134f2dd6148cefcc439ff4e39", [] ], "pointerlock.idl": [ @@ -330578,7 +331170,7 @@ ] }, "lint.whitelist": [ - "526d6b765bd3200f12380f3e526b1c403d821a6e", + "42102299396167fb05a9dbba5d48b0c1ae55ff8b", [] ], "loading": { @@ -331748,7 +332340,7 @@ ], "mime-types": { "README.md": [ - "3a2681ec74fe698912594e8be311b3b3b0196488", + "4b3c81386697d51451b666bc434e042d4949341e", [] ], "resources": { @@ -331764,6 +332356,10 @@ "a4f90f52c323fc6df7957f956f0727c9f4f54a38", [] ], + "mime-groups.json": [ + "1b5d7d54f88989064c3df112750e4e89d36c0e23", + [] + ], "mime-types.json": [ "e3cf13d113502c81f2655e6e5d9c4ad67700c4db", [] @@ -332368,10 +332964,6 @@ [] ] }, - "green-100x50.png": [ - "2733836c998fa919d9f6880fd96a32026e82ca2c", - [] - ], "text": { "2d.text.draw.fill.basic.png": [ "1e313371d828e9f5edf61480e64ea5c689653fca", @@ -345652,7 +346244,7 @@ [] ], "firefox.py": [ - "bfc3ab9a2be5e399738cece75ec8846e069207eb", + "9532bd03cb7d8bd7b21543c756ba9197707947d0", [] ], "firefox_android.py": [ @@ -345899,7 +346491,7 @@ [] ], "testloader.py": [ - "c559c94debc72641e5b8f7a47efea466ac0a7e5e", + "78967371537bed79e5a660f04c05b79decb9778b", [] ], "testrunner.py": [ @@ -351086,7 +351678,7 @@ [] ], "webxr_util.js": [ - "c9f7e81b094a29dab6c228b263547681bf0cb862", + "65c39844b15d5ed7d5d5ba3000245bbcf3bef129", [] ] }, @@ -352292,7 +352884,7 @@ [] ], "wpt.py": [ - "affba7343eadfd1b6144febf6c0083ddd970db71", + "c38fe78e917cf04301f4bff37ee8acfe07f2d1f1", [] ], "x-frame-options": { @@ -352800,6 +353392,13 @@ }, "testharness": { "2dcontext": { + "2d.filter.value.html": [ + "88b5595fd48fa00ca1be0c8044c2aad5a6429f2d", + [ + null, + {} + ] + ], "compositing": { "2d.composite.canvas.copy.html": [ "3d3166465cc6f2e8f9f18f53e499ca61e12d59bd", @@ -359305,7 +359904,7 @@ ] ], "blob-valid-after-deletion.any.js": [ - "7c7825cb421e2f1e2aacb9838db594ff16e8f30a", + "d353bc3a990a0cd66f2927552c584668d8ce97fd", [ "IndexedDB/blob-valid-after-deletion.any.html", { @@ -359338,7 +359937,7 @@ ] ], "blob-valid-before-commit.any.js": [ - "0803c9ea69c1e187bab2e6f0afe76a403973b645", + "0ec2e2903fba7cbc274c5c4055b1cee1ac3544ea", [ "IndexedDB/blob-valid-before-commit.any.html", { @@ -361861,7 +362460,7 @@ ], "key-generators": { "reading-autoincrement-indexes-cursors.any.js": [ - "d7938768fa152c20b4b58538350a51b78b38e445", + "f8f778428c98f4e189ce53b133133c5b784e1d38", [ "IndexedDB/key-generators/reading-autoincrement-indexes-cursors.any.html", { @@ -362019,7 +362618,7 @@ ] ], "reading-autoincrement-store-cursors.any.js": [ - "05971098fa893ebe58de4b2ad05d84a4965b6e0d", + "a07e5da3b0181360584f720f09f20674a13efa6f", [ "IndexedDB/key-generators/reading-autoincrement-store-cursors.any.html", { @@ -362098,7 +362697,7 @@ ] ], "reading-autoincrement-store.any.js": [ - "bbba6a335139d5b2946b5f6d71a635fd5ee014c3", + "06c4e5c6ea0970fb0ccf1e9f23ee97a00a2e1d3a", [ "IndexedDB/key-generators/reading-autoincrement-store.any.html", { @@ -375724,7 +376323,7 @@ ] ], "subsumption_algorithm-unsafe_inline.html": [ - "96f0e38699ba4b00aabb93dc7d7dda1a3589ec4e", + "a8a6a36197c04e66b2456931ed8637bc12db3fe2", [ null, {} @@ -377511,7 +378110,7 @@ ] ], "script-src-sri_hash.sub.html": [ - "2c888f46d991ebcea59c77dffb598e653039be36", + "b59206824dc8b3849a3324d943af1867c536c3b2", [ null, {} @@ -377531,8 +378130,8 @@ {} ] ], - "script-src-strict_dynamic_discard_whitelist.html": [ - "51b0b7971a09f550cd89070db74ec47d9d9c0a90", + "script-src-strict_dynamic_discard_source_expressions.html": [ + "4edef301092a090ffa65458e7bbd953a09e42528", [ null, {} @@ -377545,8 +378144,8 @@ {} ] ], - "script-src-strict_dynamic_double_policy_honor_whitelist.sub.html": [ - "314ed91e5d30e26b3e9d05f9618f06deadf9fbb3", + "script-src-strict_dynamic_double_policy_honor_source_expressions.html": [ + "39126de58f545472cf5a2d30dd2658b2a7f35472", [ null, {} @@ -377574,7 +378173,7 @@ ] ], "script-src-strict_dynamic_in_img-src.html": [ - "d640421cb74d298a8e5396dbb17238495ba15543", + "29a2a59573e8e49c799c41024b892dc4ed49e914", [ null, {} @@ -378244,7 +378843,7 @@ ] ], "stylenonce-allowed.sub.html": [ - "e190b84e8579caad5b9fa61b60ee241e65cbe7f1", + "fcedc15ec6cb95bf75ecf27e4aafaa1c44dc420f", [ null, {} @@ -378583,7 +379182,7 @@ ] ], "dedicated-worker-src-child-fallback.sub.html": [ - "9c37dfb6301406e462780ae30245f25fe44408ef", + "c16a9a543ec1c47972fef7df7cb9741f6e2ad070", [ null, {} @@ -378604,7 +379203,7 @@ ] ], "dedicated-worker-src-self-fallback.sub.html": [ - "06e79db006286c0ed4f436b3fc57b9cf257a5a48", + "69e96473bc40f9c8737f0ab7a6f166e8ee5511a8", [ null, {} @@ -378653,7 +379252,7 @@ ] ], "service-worker-src-child-fallback.https.sub.html": [ - "0053b1098aa06246161ba788bd312fa7de06aee7", + "4d6f2f333af6714ebd75f4caa5b8abea1e65908c", [ null, {} @@ -378674,7 +379273,7 @@ ] ], "service-worker-src-self-fallback.https.sub.html": [ - "58bc8cdb7a7a92bf8798ee4c023c4a2d9bc02019", + "575911207e07c15b0ece5b370778bf0f0352f7fd", [ null, {} @@ -378723,7 +379322,7 @@ ] ], "shared-worker-src-child-fallback.sub.html": [ - "53510852ef0d18b3d611d35f99f07249d64b6e1e", + "1e6a1df54b58e64c4264a58e78801b8eff9e3486", [ null, {} @@ -378744,7 +379343,7 @@ ] ], "shared-worker-src-self-fallback.sub.html": [ - "353a3a0d51b3532e6ef92c2341a863771b072b35", + "dc8370bdbef00045f3ea28521383cf15f3b285ff", [ null, {} @@ -379075,7 +379674,7 @@ ] ], "cookieStore_delete_insecure.tentative.https.any.js": [ - "911e2fbac556080ea31bedd74acf8542356454b5", + "e97401a7cce0f28096c7b7ae6a6e5b19671bb9b6", [ "cookie-store/cookieStore_delete_insecure.tentative.https.any.html", { @@ -379268,7 +379867,7 @@ ] ], "cookieStore_get_delete_basic.tentative.https.any.js": [ - "fad175d8da798709b84259c51899608e0ffd26ce", + "d71afe2044c66d2a29d04b951636c35643b4e8be", [ "cookie-store/cookieStore_get_delete_basic.tentative.https.any.html", { @@ -379395,7 +379994,7 @@ ] ], "cookieStore_set_arguments.tentative.https.any.js": [ - "6685f5fd3b7186b88b8ca36e2508b513b513257a", + "5668b858be0e2d7951e1584849408986456f7a8a", [ "cookie-store/cookieStore_set_arguments.tentative.https.any.html", { @@ -388417,6 +389016,13 @@ ] }, "grid-items": { + "grid-automatic-minimum-intrinsic-aspect-ratio-001.html": [ + "7d472716fb79238207b5910550eed51137861f0f", + [ + null, + {} + ] + ], "grid-item-dynamic-min-contribution-001.html": [ "c4ced6b2a12e0f080d6df2fccc8f74270f45683c", [ @@ -388679,7 +389285,7 @@ ] ], "grid-container-margin-border-padding-scrollbar-001.html": [ - "6aff5895953f880d088c0811e2d293e68bc9da26", + "8173361bbc88dd43b1ceadb7b330657cd620bbfe", [ null, {} @@ -389800,6 +390406,13 @@ ] ] }, + "getComputedStyle-listing.html": [ + "5970bcea6310381bf5ef17f5857b3f705756cc70", + [ + null, + {} + ] + ], "inheritance.html": [ "5546a20d6cd8aa3887735c1f9955929dedbadaab", [ @@ -405611,6 +406224,13 @@ ] ] }, + "customized-built-in-constructor-exceptions.html": [ + "32729bdb6bb2c82f54c074c7609ff5c79883a37a", + [ + null, + {} + ] + ], "disconnected-callbacks.html": [ "7f5a4d0f8e76d495acfdedfe172ef5acfdac75b4", [ @@ -406249,7 +406869,7 @@ }, "device-memory": { "device-memory.https.any.js": [ - "8f81ffc31f472f525aa360a14e5deba1e912cd90", + "4fe6f04ebc959e6468af5296ebc677c70a7cf170", [ "device-memory/device-memory.https.any.html", {} @@ -408249,7 +408869,7 @@ ] ], "Node-insertBefore.html": [ - "6977501501ddf03ed966416f5d52d0811cad2138", + "ce8b3d8a57bc975182b568192c115b05773a5345", [ null, {} @@ -408368,7 +408988,7 @@ ] ], "Node-replaceChild.html": [ - "e942cfa3ec44c0ca5f3692eefdd6e58f894850a7", + "74aac67d432af53fac341a33d24feb8919b3c2e6", [ null, {} @@ -408396,7 +409016,7 @@ ] ], "ParentNode-append.html": [ - "dcc398f3f586d1d627d0ffa0c689f3b1f67ece16", + "4e101f73a25719af97280f56cbfe8b463e1f5339", [ null, {} @@ -408410,7 +409030,7 @@ ] ], "ParentNode-prepend.html": [ - "644693ffe6d816224bbbd730b90414f19f1c9e12", + "f6aa38a2dd58a18ff2020fba3ee0b2b6fa0aefd9", [ null, {} @@ -408483,6 +409103,13 @@ {} ] ], + "ParentNode-replaceChildren.html": [ + "6557db4412847be59f4ecedc89731d6fa89314b9", + [ + null, + {} + ] + ], "ProcessingInstruction-escapes-1.xhtml": [ "d629a8464b7e171862b0d6989fb72215e0e45833", [ @@ -427278,21 +427905,21 @@ ] ], "stale-css.html": [ - "f56260fdb45c0c2c60b4d76f63a76389df818b11", + "603a60c8bbadde5847d7387035100a277a3572c5", [ null, {} ] ], "stale-image.html": [ - "0a08f81729de49985c6575e1a7a5fcb77d3a0ee2", + "f90e293bc40c9fd2a06dc8e346080ef682bb5423", [ null, {} ] ], "stale-script.html": [ - "68793e50056bc6053ea410d658aed373d19f9a41", + "f5317482c488bc0c8e5be5e9789db711cb04e085", [ null, {} @@ -427786,6 +428413,15 @@ ] ] }, + "hit-test": { + "idlharness.https.html": [ + "b7f67845470efa9730bcc754c098b5457e089f34", + [ + null, + {} + ] + ] + }, "hr-time": { "basic.any.js": [ "364dd81a3448188bd76f6ff410807bfcca93177d", @@ -446065,8 +446701,64 @@ {} ] ], + "module-delayed.html": [ + "f9f9a1c0610fed927ef437524e1aadd5ce3cb862", + [ + null, + {} + ] + ], + "module-dynamic-import.html": [ + "02c6b9cf8d283af498a1c3a6525076983c81ad5c", + [ + null, + {} + ] + ], + "module-static-import-delayed.html": [ + "498d1012a077a4439d74d0892ee24e8b63c6af4b", + [ + null, + {} + ] + ], + "module-static-import.html": [ + "d725854d86694958ebe23acd1fea201350a060c4", + [ + null, + {} + ] + ], + "module-tla-delayed.html": [ + "f269dcbcb9399e0cd08306c529bcb2de97b5cdcc", + [ + null, + {} + ] + ], + "module-tla-immediate-promise.html": [ + "430f874b656d2f84459cbe8f1605f0e959d77218", + [ + null, + {} + ] + ], + "module-tla-import.html": [ + "f59c3c0abe705b968ebabef504cd3a6c56830338", + [ + null, + {} + ] + ], + "module-tla-promise.html": [ + "5fc30a8b0e74f496106f4e5b83439958c3118056", + [ + null, + {} + ] + ], "module.html": [ - "32f0370577a5a87783588429aa79efe0e4f60f4c", + "7e970d3fd92bc09a40481d9cce64aa472d0be9ae", [ null, {} @@ -447338,10 +448030,10 @@ }, "system-state-and-capabilities": { "the-navigator-object": { - "historical.window.js": [ - "c27845e6a7d4e2761b25021b2baa1b4f83aa53c5", + "historical.https.window.js": [ + "f6b9db078e0ecf94955330c15def280c0ca30c4e", [ - "html/webappapis/system-state-and-capabilities/the-navigator-object/historical.window.html", + "html/webappapis/system-state-and-capabilities/the-navigator-object/historical.https.window.html", {} ] ], @@ -447399,7 +448091,7 @@ ] ], "protocol.https.html": [ - "c6fbeb65c55bc16f3d7c0757bc52373b34d8b975", + "18c7ad1b42b06f8a148c998361bad0d5e7ad788c", [ null, {} @@ -453619,7 +454311,7 @@ ] ], "sandboxed_FileSystemBaseHandle-IndexedDB.tentative.https.any.js": [ - "6610810eb99b742d02842d7f3f83baa345537ff0", + "7f0fc4a7212db3c4bc19f59d0ce265ccf5536bae", [ "native-file-system/sandboxed_FileSystemBaseHandle-IndexedDB.tentative.https.any.html", { @@ -467197,6 +467889,15 @@ ] } }, + "page-lifecycle": { + "idlharness.html": [ + "08b2b054fbad3b41617975a9c2475fe54bc9910d", + [ + null, + {} + ] + ] + }, "page-visibility": { "idlharness.window.js": [ "8cc2f83095c1ce7ad04a06406a0d79b876aee32b", @@ -468641,7 +469342,7 @@ ] ], "webtiming-resolution.any.js": [ - "46e0489352f09767dc847615bd64464946f9088e", + "d869c7c52d55d69e2123f64d486ed1e3235d3fb7", [ "performance-timeline/webtiming-resolution.any.html", {} @@ -468950,7 +469651,7 @@ ] }, "idlharness.window.js": [ - "89a994af3048cc0b9fc3212fd6f1497bc717208a", + "90e812598256bc887c81753cf4426efd040870e6", [ "pointerevents/idlharness.window.html", { @@ -481101,7 +481802,7 @@ ] ], "buffered-flag.any.js": [ - "63a386159f34317757f239d0681e395c320090b4", + "b46fd00e69ddfc3ac57abcd20c2d092a18220490", [ "resource-timing/buffered-flag.any.html", {} @@ -482992,7 +483693,7 @@ ] ], "fetch-on-the-right-interface.https.any.js": [ - "9a9c8198057e3b98f5b278fcd4778a71a6211759", + "44946d43b62aac1367073ac72ac385037b403087", [ "service-workers/service-worker/ServiceWorkerGlobalScope/fetch-on-the-right-interface.https.any.serviceworker.html", { @@ -486157,15 +486858,6 @@ } ] ], - "SpeechSynthesis-speak-ownership.html": [ - "269017af6927ff2cb01345cb6934ac0fed4ea2a8", - [ - null, - { - "testdriver": true - } - ] - ], "SpeechSynthesis-speak-twice.html": [ "3e0388b9cf37cae2075380faf48414a48b4092e9", [ @@ -495525,6 +496217,15 @@ null, {} ] + ], + "focus-management-expectations.html": [ + "1845c15d71679276b6fbf4a19188d111da5ea70b", + [ + null, + { + "testdriver": true + } + ] ] }, "mouse-events": { @@ -505854,12 +506555,21 @@ ] ], "RTCPeerConnection-operations.https.html": [ - "a0921d315a3c20a2237cade41c51b2a34306b5d7", + "28ae3afcd73e4100345edddc505895add26ea56d", [ null, {} ] ], + "RTCPeerConnection-perfect-negotiation.https.html": [ + "ad2725c33ca66b303959f32d107ae516bade4a61", + [ + null, + { + "timeout": "long" + } + ] + ], "RTCPeerConnection-remote-track-mute.https.html": [ "c280a7d44d8d2a477f2600c741ed68903e516651", [ @@ -516397,7 +517107,7 @@ ] ], "event-abort.any.js": [ - "9b38ccf9c9e19765111b96df595abf780f6bfeb8", + "5b17ece0085aed8bbe2723a4710dbbfd63f4573d", [ "xhr/event-abort.any.html", { @@ -516429,7 +517139,7 @@ ] ], "event-error.sub.any.js": [ - "df63dc05bfa41cc4da9679d020b4cbdbb4e906a4", + "62a158cdcfbcc80fb6f6a7db6f6ffd88e6074c5a", [ "xhr/event-error.sub.any.html", { @@ -516454,7 +517164,7 @@ ] ], "event-load.any.js": [ - "72e46a5cea81ec06a981d973c564db4c7d9f3cb7", + "dcb92cc980dc9ebcacac035c721f9843e20352c1", [ "xhr/event-load.any.html", { @@ -516479,7 +517189,7 @@ ] ], "event-loadend.any.js": [ - "7bd1844b378c0f63da44a896e398e8b1edcd9cf5", + "16087b52967c01f7738aa65840ae4d16179e52be", [ "xhr/event-loadend.any.html", { @@ -516504,7 +517214,7 @@ ] ], "event-loadstart-upload.any.js": [ - "0f41cd1286b74a7c0f0def2fc9b16f4a81dc3c97", + "3918adb66a953dcd716dfc252e250236dce87959", [ "xhr/event-loadstart-upload.any.html", { @@ -516529,7 +517239,7 @@ ] ], "event-loadstart.any.js": [ - "4778404a00ef5fa2302d0b93776e1c5039a1a5a1", + "55af4c3163150f0071ad0cf64e2c5cb0eae79212", [ "xhr/event-loadstart.any.html", { @@ -516554,7 +517264,7 @@ ] ], "event-progress.any.js": [ - "0e7c3a42c7df6872d9e23a39f2164a185bf251fc", + "094d36181171d5a5c79003f61a63ff1536bf7014", [ "xhr/event-progress.any.html", { @@ -516589,7 +517299,7 @@ ] ], "event-readystate-sync-open.any.js": [ - "321635e7dea40c28d43490c7846ebfdf97993af2", + "a8a4fe7f9a196b6ab01d84bef1e9f0b9b6184d5d", [ "xhr/event-readystate-sync-open.any.html", { @@ -516614,7 +517324,7 @@ ] ], "event-readystatechange-loaded.any.js": [ - "1e4467aaebdaf9bf192b16d679ee9f92488dba25", + "a33e6f892278ef6d31a870bd1fe35ef42f0d2995", [ "xhr/event-readystatechange-loaded.any.html", { @@ -516639,7 +517349,7 @@ ] ], "event-timeout-order.any.js": [ - "b35e908a9d8c102aa9019649fad6c591779d60c6", + "55319814a90064786c726abf6d73c75e6e4b45d1", [ "xhr/event-timeout-order.any.html", { @@ -516672,7 +517382,7 @@ ] ], "event-timeout.any.js": [ - "d114b08b3e124eef560a3fd7bce1247cf43a347e", + "da8ca11bb8ea1a8ef673be20ae2de8715a4d1130", [ "xhr/event-timeout.any.html", { @@ -516697,7 +517407,7 @@ ] ], "event-upload-progress-crossorigin.any.js": [ - "1036f2b14f0a39744d5b92ea95c6f2c5bf0c67b7", + "9f4c44aabe75e37f66788cd9d7b88f5827689e29", [ "xhr/event-upload-progress-crossorigin.any.html", { @@ -516730,7 +517440,7 @@ ] ], "event-upload-progress.any.js": [ - "5d1546757ba424c6bce0c14412deb81494198e8a", + "87223c172d50bb01379a86075d355e5a4bcbbcfd", [ "xhr/event-upload-progress.any.html", { @@ -539243,6 +539953,17 @@ ] ] }, + "css-grid": { + "layout-algorithm": { + "grid-automatic-minimum-for-auto-rows-001.html": [ + "77e9c22294d9dd11ac5977630696325bc76b913e", + [ + null, + {} + ] + ] + } + }, "css-images": { "image-fit-001.xht": [ "169d55c0f2e9bf93fd9851f7fb43eb4493d14b39", diff --git a/tests/wpt/metadata/css/CSS2/floats/hit-test-floats-004.html.ini b/tests/wpt/metadata/css/CSS2/floats/hit-test-floats-003.html.ini index 4bfb0c2053a..f29da48a2a0 100644 --- a/tests/wpt/metadata/css/CSS2/floats/hit-test-floats-004.html.ini +++ b/tests/wpt/metadata/css/CSS2/floats/hit-test-floats-003.html.ini @@ -1,4 +1,4 @@ -[hit-test-floats-004.html] +[hit-test-floats-003.html] [Miss float below something else] expected: FAIL diff --git a/tests/wpt/metadata/css/cssom-view/elementFromPosition.html.ini b/tests/wpt/metadata/css/cssom-view/elementFromPosition.html.ini index 85e94926cb3..5733d536fd3 100644 --- a/tests/wpt/metadata/css/cssom-view/elementFromPosition.html.ini +++ b/tests/wpt/metadata/css/cssom-view/elementFromPosition.html.ini @@ -21,3 +21,6 @@ [test the top of layer] expected: FAIL + [test some point of the element: top left corner] + expected: FAIL + diff --git a/tests/wpt/metadata/css/cssom-view/elementsFromPoint-iframes.html.ini b/tests/wpt/metadata/css/cssom-view/elementsFromPoint-iframes.html.ini index 171592fc08f..6ef8bb1049f 100644 --- a/tests/wpt/metadata/css/cssom-view/elementsFromPoint-iframes.html.ini +++ b/tests/wpt/metadata/css/cssom-view/elementsFromPoint-iframes.html.ini @@ -2,3 +2,6 @@ [elementsFromPoint on the root document for points in iframe elements] expected: FAIL + [elementsFromPoint on inner documents] + expected: FAIL + diff --git a/tests/wpt/metadata/custom-elements/customized-built-in-constructor-exceptions.html.ini b/tests/wpt/metadata/custom-elements/customized-built-in-constructor-exceptions.html.ini new file mode 100644 index 00000000000..10c7e55eab6 --- /dev/null +++ b/tests/wpt/metadata/custom-elements/customized-built-in-constructor-exceptions.html.ini @@ -0,0 +1,2 @@ +[customized-built-in-constructor-exceptions.html] + expected: CRASH diff --git a/tests/wpt/metadata/dom/nodes/ParentNode-replaceChildren.html.ini b/tests/wpt/metadata/dom/nodes/ParentNode-replaceChildren.html.ini new file mode 100644 index 00000000000..ae9d14fd80b --- /dev/null +++ b/tests/wpt/metadata/dom/nodes/ParentNode-replaceChildren.html.ini @@ -0,0 +1,76 @@ +[ParentNode-replaceChildren.html] + [DocumentFragment.replaceChildren() with null as an argument, on a parent having a child.] + expected: FAIL + + [DocumentFragment.replaceChildren() with only text as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() with null as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() without any argument, on a parent having no child.] + expected: FAIL + + [If node is a host-including inclusive ancestor of parent, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is an Element and parent is a document with another element, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [DocumentFragment.replaceChildren() with null as an argument, on a parent having no child.] + expected: FAIL + + [DocumentFragment.replaceChildren() with one element and text as argument, on a parent having a child.] + expected: FAIL + + [Element.replaceChildren() with null as an argument, on a parent having a child.] + expected: FAIL + + [DocumentFragment.replaceChildren() with only one element as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() should move nodes in the right order] + expected: FAIL + + [If node is a Text node and parent is a document, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is a DocumentFragment with an element and parent is a document with another element, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [DocumentFragment.replaceChildren() with undefined as an argument, on a parent having no child.] + expected: FAIL + + [If node is a doctype and parent is not a document, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is a doctype and parent is a document with another doctype, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [If node is a DocumentFragment with multiple elements and parent is a document, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [Element.replaceChildren() with undefined as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() with only one element as an argument, on a parent having no child.] + expected: FAIL + + [Element.replaceChildren() with one element and text as argument, on a parent having a child.] + expected: FAIL + + [DocumentFragment.replaceChildren() should move nodes in the right order] + expected: FAIL + + [If node is a doctype and parent is a document with an element, then throw a HierarchyRequestError DOMException.] + expected: FAIL + + [Element.replaceChildren() with only text as an argument, on a parent having no child.] + expected: FAIL + + [DocumentFragment.replaceChildren() without any argument, on a parent having no child.] + expected: FAIL + + [If node is not a DocumentFragment, DocumentType, Element, Text, ProcessingInstruction, or Comment node, then throw a HierarchyRequestError DOMException.] + expected: FAIL + diff --git a/tests/wpt/metadata/fetch/content-type/response.window.js.ini b/tests/wpt/metadata/fetch/content-type/response.window.js.ini index 2db03661a2f..e42fdfc0ba9 100644 --- a/tests/wpt/metadata/fetch/content-type/response.window.js.ini +++ b/tests/wpt/metadata/fetch/content-type/response.window.js.ini @@ -315,18 +315,21 @@ [<iframe>: combined response Content-Type: text/html;" \\" text/plain] expected: FAIL - [<iframe>: separate response Content-Type: text/html */*;charset=gbk] + [<iframe>: separate response Content-Type: text/plain */*] expected: FAIL - [<iframe>: separate response Content-Type: text/plain */*] + [<iframe>: combined response Content-Type: text/html;" text/plain] + expected: FAIL + + [<iframe>: combined response Content-Type: */* text/html] expected: FAIL - [<iframe>: combined response Content-Type: text/html */*;charset=gbk] + [<iframe>: combined response Content-Type: text/html;charset=gbk text/plain text/html] expected: FAIL - [<iframe>: separate response Content-Type: text/html;" \\" text/plain] + [<iframe>: separate response Content-Type: text/html;" text/plain] expected: FAIL - [<iframe>: separate response Content-Type: text/plain */*;charset=gbk] + [<iframe>: separate response Content-Type: text/html;x=" text/plain] expected: FAIL diff --git a/tests/wpt/metadata/fetch/content-type/script.window.js.ini b/tests/wpt/metadata/fetch/content-type/script.window.js.ini index 2d5faa72ac7..9c6c5193b99 100644 --- a/tests/wpt/metadata/fetch/content-type/script.window.js.ini +++ b/tests/wpt/metadata/fetch/content-type/script.window.js.ini @@ -56,3 +56,9 @@ [separate text/javascript;charset=windows-1252 error text/javascript] expected: FAIL + [separate text/javascript x/x] + expected: FAIL + + [separate text/javascript; charset=windows-1252 text/javascript] + expected: FAIL + diff --git a/tests/wpt/metadata/fetch/nosniff/parsing-nosniff.window.js.ini b/tests/wpt/metadata/fetch/nosniff/parsing-nosniff.window.js.ini index 70efd28ddfc..30e1b851fd4 100644 --- a/tests/wpt/metadata/fetch/nosniff/parsing-nosniff.window.js.ini +++ b/tests/wpt/metadata/fetch/nosniff/parsing-nosniff.window.js.ini @@ -11,6 +11,3 @@ [X-Content-Type-Options%3A%20nosniff%2C%2C%40%23%24%23%25%25%26%5E%26%5E*()()11!] expected: FAIL - [X-Content-Type-Options%3A%20no%0D%0AX-Content-Type-Options%3A%20nosniff] - expected: FAIL - diff --git a/tests/wpt/metadata/html/browsers/history/the-history-interface/traverse_the_history_4.html.ini b/tests/wpt/metadata/html/browsers/history/the-history-interface/traverse_the_history_4.html.ini new file mode 100644 index 00000000000..385376c7321 --- /dev/null +++ b/tests/wpt/metadata/html/browsers/history/the-history-interface/traverse_the_history_4.html.ini @@ -0,0 +1,4 @@ +[traverse_the_history_4.html] + [Multiple history traversals, last would be aborted] + expected: FAIL + diff --git a/tests/wpt/metadata/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini b/tests/wpt/metadata/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini index e836f08c992..8a8e71411f3 100644 --- a/tests/wpt/metadata/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini +++ b/tests/wpt/metadata/html/browsers/history/the-location-interface/location-protocol-setter-non-broken.html.ini @@ -24,9 +24,6 @@ [Set data URL frame location.protocol to data] expected: FAIL - [Set data URL frame location.protocol to file] - expected: FAIL - [Set data URL frame location.protocol to http+x] expected: FAIL diff --git a/tests/wpt/metadata/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini b/tests/wpt/metadata/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini index f4d11768961..6b68e9094e4 100644 --- a/tests/wpt/metadata/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini +++ b/tests/wpt/metadata/html/interaction/focus/the-autofocus-attribute/supported-elements.html.ini @@ -1,5 +1,4 @@ [supported-elements.html] - expected: TIMEOUT [Contenteditable element should support autofocus] expected: FAIL @@ -7,10 +6,10 @@ expected: FAIL [Host element with delegatesFocus including no focusable descendants should be skipped] - expected: TIMEOUT + expected: FAIL [Area element should support autofocus] - expected: NOTRUN + expected: FAIL [Host element with delegatesFocus should support autofocus] expected: FAIL diff --git a/tests/wpt/metadata/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini b/tests/wpt/metadata/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini index 71edac2c5ed..dc856a3d5a3 100644 --- a/tests/wpt/metadata/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini +++ b/tests/wpt/metadata/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html.ini @@ -1,6 +1,5 @@ [iframe_sandbox_popups_nonescaping-3.html] type: testharness - expected: CRASH [Check that popups from a sandboxed iframe do not escape the sandbox] - expected: NOTRUN + expected: FAIL diff --git a/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html.ini b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html.ini new file mode 100644 index 00000000000..59a54fe88e4 --- /dev/null +++ b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html.ini @@ -0,0 +1,4 @@ +[module-delayed.html] + [async document.write in a module] + expected: FAIL + diff --git a/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html.ini b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html.ini new file mode 100644 index 00000000000..30c8d2fd9d5 --- /dev/null +++ b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html.ini @@ -0,0 +1,5 @@ +[module-dynamic-import.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html.ini b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html.ini new file mode 100644 index 00000000000..6527fa02f03 --- /dev/null +++ b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html.ini @@ -0,0 +1,5 @@ +[module-tla-delayed.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html.ini b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html.ini new file mode 100644 index 00000000000..1300a9536d6 --- /dev/null +++ b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html.ini @@ -0,0 +1,5 @@ +[module-tla-immediate-promise.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html.ini b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html.ini new file mode 100644 index 00000000000..30d23c291f1 --- /dev/null +++ b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html.ini @@ -0,0 +1,4 @@ +[module-tla-import.html] + [document.write in an imported module] + expected: FAIL + diff --git a/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html.ini b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html.ini new file mode 100644 index 00000000000..8694e58234a --- /dev/null +++ b/tests/wpt/metadata/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html.ini @@ -0,0 +1,5 @@ +[module-tla-promise.html] + expected: TIMEOUT + [document.write in an imported module] + expected: TIMEOUT + diff --git a/tests/wpt/metadata/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini b/tests/wpt/metadata/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini index edae5e5adcd..01f7b72cbe7 100644 --- a/tests/wpt/metadata/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini +++ b/tests/wpt/metadata/html/webappapis/scripting/events/compile-event-handler-settings-objects.html.ini @@ -5,5 +5,5 @@ expected: TIMEOUT [The entry settings object while executing the compiled callback via Web IDL's invoke must be that of the node document] - expected: TIMEOUT + expected: FAIL diff --git a/tests/wpt/metadata/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini b/tests/wpt/metadata/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini index 2f985b21244..ba902d16c5b 100644 --- a/tests/wpt/metadata/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini +++ b/tests/wpt/metadata/webaudio/the-audio-api/the-audiobuffersourcenode-interface/audiobuffersource-multi-channels.html.ini @@ -161,3 +161,6 @@ [X Rendered audio for channel 5 does not equal [0,0.0626220703125,0.125030517578125,0.18695068359375,0.24810791015625,0.308319091796875,0.3673095703125,0.42486572265625,0.480743408203125,0.53472900390625,0.58660888671875,0.636199951171875,0.68328857421875,0.727691650390625,0.76922607421875,0.8077392578125...\] with an element-wise tolerance of {"absoluteThreshold":0.000030517578125,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[1\]\t3.6732959747314453e-1\t6.2622070312500000e-2\t3.0470752716064453e-1\t4.8658168859649127e+0\t3.0517578125000000e-5\n\t[2\]\t6.8329977989196777e-1\t1.2503051757812500e-1\t5.5826926231384277e-1\t4.4650639949963384e+0\t3.0517578125000000e-5\n\t[3\]\t9.0373212099075317e-1\t1.8695068359375000e-1\t7.1678143739700317e-1\t3.8340669508039502e+0\t3.0517578125000000e-5\n\t[4\]\t9.9780619144439697e-1\t2.4810791015625000e-1\t7.4969828128814697e-1\t3.0216621502152523e+0\t3.0517578125000000e-5\n\t[5\]\t9.5236867666244507e-1\t3.0831909179687500e-1\t6.4404958486557007e-1\t2.0889059484187866e+0\t3.0517578125000000e-5\n\t...and 44050 more errors.\n\tMax AbsError of 1.9986916780471802e+0 at index of 42250.\n\t[42250\]\t9.9994289875030518e-1\t-9.9874877929687500e-1\t1.9986916780471802e+0\t2.0011956154322119e+0\t3.0517578125000000e-5\n\tMax RelError of Infinity at index of 14112.\n\t[14112\]\t-9.5105654001235962e-1\t0.0000000000000000e+0\t9.5105654001235962e-1\tInfinity\t3.0517578125000000e-5\n] expected: FAIL + [X Rendered audio for channel 5 does not equal [0,0.0626220703125,0.125030517578125,0.18695068359375,0.24810791015625,0.308319091796875,0.3673095703125,0.42486572265625,0.480743408203125,0.53472900390625,0.58660888671875,0.636199951171875,0.68328857421875,0.727691650390625,0.76922607421875,0.8077392578125...\] with an element-wise tolerance of {"absoluteThreshold":0.000030517578125,"relativeThreshold":0}.\n\tIndex\tActual\t\t\tExpected\t\tAbsError\t\tRelError\t\tTest threshold\n\t[1\]\t3.6732959747314453e-1\t6.2622070312500000e-2\t3.0470752716064453e-1\t4.8658168859649127e+0\t3.0517578125000000e-5\n\t[2\]\t6.8329977989196777e-1\t1.2503051757812500e-1\t5.5826926231384277e-1\t4.4650639949963384e+0\t3.0517578125000000e-5\n\t[3\]\t9.0373212099075317e-1\t1.8695068359375000e-1\t7.1678143739700317e-1\t3.8340669508039502e+0\t3.0517578125000000e-5\n\t[4\]\t9.9780619144439697e-1\t2.4810791015625000e-1\t7.4969828128814697e-1\t3.0216621502152523e+0\t3.0517578125000000e-5\n\t[5\]\t9.5236867666244507e-1\t3.0831909179687500e-1\t6.4404958486557007e-1\t2.0889059484187866e+0\t3.0517578125000000e-5\n\t...and 42283 more errors.\n\tMax AbsError of 1.9962286949157715e+0 at index of 36587.\n\t[36587\]\t9.9879217147827148e-1\t-9.9743652343750000e-1\t1.9962286949157715e+0\t2.0013591321441684e+0\t3.0517578125000000e-5\n\tMax RelError of Infinity at index of 15876.\n\t[15876\]\t5.8778524398803711e-1\t0.0000000000000000e+0\t5.8778524398803711e-1\tInfinity\t3.0517578125000000e-5\n] + expected: FAIL + diff --git a/tests/wpt/metadata/webmessaging/with-ports/018.html.ini b/tests/wpt/metadata/webmessaging/with-ports/018.html.ini new file mode 100644 index 00000000000..663a1f8fa30 --- /dev/null +++ b/tests/wpt/metadata/webmessaging/with-ports/018.html.ini @@ -0,0 +1,5 @@ +[018.html] + expected: TIMEOUT + [origin of the script that invoked the method, javascript:] + expected: TIMEOUT + diff --git a/tests/wpt/web-platform-tests/2dcontext/2d.filter.value.html b/tests/wpt/web-platform-tests/2dcontext/2d.filter.value.html new file mode 100644 index 00000000000..88b5595fd48 --- /dev/null +++ b/tests/wpt/web-platform-tests/2dcontext/2d.filter.value.html @@ -0,0 +1,56 @@ +<!DOCTYPE html> +<!-- DO NOT EDIT! This test has been generated by /2dcontext/tools/gentest.py. --> +<title>Canvas test: 2d.filter.value</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="/2dcontext/resources/canvas-tests.js"></script> +<link rel="stylesheet" href="/2dcontext/resources/canvas-tests.css"> +<body class="show_output"> + +<h1>2d.filter.value</h1> +<p class="desc">test if ctx.filter works correctly</p> + + +<p class="output">Actual output:</p> +<canvas id="c" class="output" width="100" height="50"><p class="fallback">FAIL (fallback content)</p></canvas> + +<ul id="d"></ul> +<script> +var t = async_test("test if ctx.filter works correctly"); +_addTest(function(canvas, ctx) { + +_assert(ctx.filter == 'none', "ctx.filter == 'none'"); +ctx.filter = 'blur(5px)'; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); +ctx.save(); +ctx.filter = 'none'; +_assert(ctx.filter == 'none', "ctx.filter == 'none'"); +ctx.restore(); +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); + +ctx.filter = 'blur(10)'; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); +ctx.filter = 'blur 10px'; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); + +ctx.filter = 'inherit'; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); +ctx.filter = 'initial'; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); +ctx.filter = 'unset'; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); + +ctx.filter = ''; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); +ctx.filter = null; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); +ctx.filter = undefined; +_assert(ctx.filter == 'blur(5px)', "ctx.filter == 'blur(5px)'"); + +ctx.filter = 'blur( 5px)'; +assert_equals(ctx.filter, 'blur( 5px)'); + + +}); +</script> + diff --git a/tests/wpt/web-platform-tests/2dcontext/green-100x50.png b/tests/wpt/web-platform-tests/2dcontext/green-100x50.png Binary files differdeleted file mode 100644 index 2733836c998..00000000000 --- a/tests/wpt/web-platform-tests/2dcontext/green-100x50.png +++ /dev/null diff --git a/tests/wpt/web-platform-tests/2dcontext/tools/tests2d.yaml b/tests/wpt/web-platform-tests/2dcontext/tools/tests2d.yaml index d8ccbe13f6d..9dad482562b 100644 --- a/tests/wpt/web-platform-tests/2dcontext/tools/tests2d.yaml +++ b/tests/wpt/web-platform-tests/2dcontext/tools/tests2d.yaml @@ -10328,3 +10328,41 @@ var rect = canvas.getBoundingClientRect(); @assert Math.round(rect.top) === -8; @assert Math.round(rect.left) === 200; + +- name: 2d.filter.value + desc: test if ctx.filter works correctly + testing: + - 2d.filter.value + code: | + @assert ctx.filter == 'none'; + ctx.filter = 'blur(5px)'; + @assert ctx.filter == 'blur(5px)'; + ctx.save(); + ctx.filter = 'none'; + @assert ctx.filter == 'none'; + ctx.restore(); + @assert ctx.filter == 'blur(5px)'; + + ctx.filter = 'blur(10)'; + @assert ctx.filter == 'blur(5px)'; + ctx.filter = 'blur 10px'; + @assert ctx.filter == 'blur(5px)'; + + ctx.filter = 'inherit'; + @assert ctx.filter == 'blur(5px)'; + ctx.filter = 'initial'; + @assert ctx.filter == 'blur(5px)'; + ctx.filter = 'unset'; + @assert ctx.filter == 'blur(5px)'; + + ctx.filter = ''; + @assert ctx.filter == 'blur(5px)'; + ctx.filter = null; + @assert ctx.filter == 'blur(5px)'; + ctx.filter = undefined; + @assert ctx.filter == 'blur(5px)'; + + ctx.filter = 'blur( 5px)'; + assert_equals(ctx.filter, 'blur( 5px)'); + + diff --git a/tests/wpt/web-platform-tests/IndexedDB/blob-valid-after-deletion.any.js b/tests/wpt/web-platform-tests/IndexedDB/blob-valid-after-deletion.any.js index 7c7825cb421..d353bc3a990 100644 --- a/tests/wpt/web-platform-tests/IndexedDB/blob-valid-after-deletion.any.js +++ b/tests/wpt/web-platform-tests/IndexedDB/blob-valid-after-deletion.any.js @@ -50,4 +50,4 @@ indexeddb_test( }); }); }, - "Blobs stay alive after their records are deleted.");
\ No newline at end of file + "Blobs stay alive after their records are deleted."); diff --git a/tests/wpt/web-platform-tests/IndexedDB/blob-valid-before-commit.any.js b/tests/wpt/web-platform-tests/IndexedDB/blob-valid-before-commit.any.js index 0803c9ea69c..0ec2e2903fb 100644 --- a/tests/wpt/web-platform-tests/IndexedDB/blob-valid-before-commit.any.js +++ b/tests/wpt/web-platform-tests/IndexedDB/blob-valid-before-commit.any.js @@ -38,4 +38,4 @@ indexeddb_test( }); }); }, - "Blobs can be read back before their records are committed.");
\ No newline at end of file + "Blobs can be read back before their records are committed."); diff --git a/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-indexes-cursors.any.js b/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-indexes-cursors.any.js index d7938768fa1..f8f778428c9 100644 --- a/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-indexes-cursors.any.js +++ b/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-indexes-cursors.any.js @@ -85,4 +85,4 @@ promise_test(async testCase => { database.close(); }, 'IDBIndex.openKeyCursor() iterates over an index not covering the ' + - 'autoincrement key');
\ No newline at end of file + 'autoincrement key'); diff --git a/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store-cursors.any.js b/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store-cursors.any.js index 05971098fa8..a07e5da3b01 100644 --- a/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store-cursors.any.js +++ b/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store-cursors.any.js @@ -35,4 +35,4 @@ promise_test(async testCase => { } database.close(); -}, 'IDBObjectStore.openKeyCursor() iterates over an autoincrement store');
\ No newline at end of file +}, 'IDBObjectStore.openKeyCursor() iterates over an autoincrement store'); diff --git a/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store.any.js b/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store.any.js index bbba6a33513..06c4e5c6ea0 100644 --- a/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store.any.js +++ b/tests/wpt/web-platform-tests/IndexedDB/key-generators/reading-autoincrement-store.any.js @@ -46,4 +46,4 @@ promise_test(async testCase => { } database.close(); -}, 'IDBObjectStore.get() for an autoincrement store');
\ No newline at end of file +}, 'IDBObjectStore.get() for an autoincrement store'); diff --git a/tests/wpt/web-platform-tests/content-security-policy/embedded-enforcement/subsumption_algorithm-unsafe_inline.html b/tests/wpt/web-platform-tests/content-security-policy/embedded-enforcement/subsumption_algorithm-unsafe_inline.html index 96f0e38699b..a8a6a36197c 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/embedded-enforcement/subsumption_algorithm-unsafe_inline.html +++ b/tests/wpt/web-platform-tests/content-security-policy/embedded-enforcement/subsumption_algorithm-unsafe_inline.html @@ -69,12 +69,12 @@ "returned_csp_1": "style-src 'unsafe-inline'", "returned_csp_2": null, "expected": IframeLoad.EXPECT_BLOCK }, - { "name": "Returned csp whitelists a nonce.", + { "name": "Returned csp allows a nonce.", "required_csp": "style-src http://example1.com/foo/ 'self' 'unsafe-inline'", "returned_csp_1": "style-src 'unsafe-inline' 'nonce-abc'", "returned_csp_2": "style-src 'nonce-abc'", "expected": IframeLoad.EXPECT_BLOCK }, - { "name": "Returned csp whitelists a hash.", + { "name": "Returned csp allows a hash.", "required_csp": "style-src http://example1.com/foo/ 'self' 'unsafe-inline'", "returned_csp_1": "style-src 'unsafe-inline' 'sha256-abc123'", "returned_csp_2": "style-src 'sha256-abc123'", diff --git a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-sri_hash.sub.html b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-sri_hash.sub.html index 2c888f46d99..b59206824dc 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-sri_hash.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-sri_hash.sub.html @@ -49,11 +49,11 @@ './simpleSourcedScript.js', 'sha256-L7/UQ9VWpyG7C9RDEC4ctS5hI3Zcw+ta+haPGlByG9c= sha256-xyz', false ], - [ 'crossorigin no integrity but whitelisted host', + [ 'crossorigin no integrity but allowed host', crossorigin_base + '/content-security-policy/script-src/crossoriginScript.js', '', true ], - [ 'crossorigin mismatched integrity but whitelisted host', + [ 'crossorigin mismatched integrity but allowed host', crossorigin_base + '/content-security-policy/script-src/crossoriginScript.js', 'sha256-kKJ5c48yxzaaSBupJSCmY50hkD8xbVgZgLHLtmnkeAo=', true ], diff --git a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_whitelist.html b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_source_expressions.html index 51b0b7971a0..4edef301092 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_whitelist.html +++ b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_source_expressions.html @@ -2,7 +2,7 @@ <html> <head> - <title>Whitelists are discarded with `strict-dynamic` in the script-src directive.</title> + <title>Source expressions are discarded with `strict-dynamic` in the script-src directive.</title> <script src='/resources/testharness.js' nonce='dummy'></script> <script src='/resources/testharnessreport.js' nonce='dummy'></script> @@ -10,22 +10,22 @@ </head> <body> - <h1>Whitelists are discarded with `strict-dynamic` in the script-src directive.</h1> + <h1>Source expressions are discarded with `strict-dynamic` in the script-src directive.</h1> <div id='log'></div> <script nonce='dummy'> async_test(function(t) { window.addEventListener('message', t.step_func(function(e) { - if (e.data === 'whitelistedScript') { - assert_unreached('Whitelisted script without a correct nonce is not allowed with `strict-dynamic`.'); + if (e.data === 'allowedScript') { + assert_unreached('Allowed scripts without a correct nonce are not permitted with `strict-dynamic`.'); } })); window.addEventListener('securitypolicyviolation', t.step_func_done(function(e) { assert_equals(e.effectiveDirective, 'script-src-elem'); })); - }, 'Whitelisted script without a correct nonce is not allowed with `strict-dynamic`.'); + }, 'Allowed scripts without a correct nonce are not permitted with `strict-dynamic`.'); </script> - <script id='whitelistedScript' src='simpleSourcedScript.js'></script> + <script id='allowedScript' src='simpleSourcedScript.js'></script> </body> diff --git a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_whitelist.html.headers b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_source_expressions.html.headers index 8499eb0559d..8499eb0559d 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_whitelist.html.headers +++ b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_discard_source_expressions.html.headers diff --git a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_whitelist.sub.html b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_source_expressions.html index 314ed91e5d3..39126de58f5 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_whitelist.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_source_expressions.html @@ -2,7 +2,7 @@ <html> <head> - <title>Whitelists in a separate policy are honored with `strict-dynamic` in the script-src directive.</title> + <title>Source expressions in a separate policy are honored with `strict-dynamic` in the script-src directive.</title> <script src='/resources/testharness.js' nonce='dummy'></script> <script src='/resources/testharnessreport.js' nonce='dummy'></script> @@ -13,35 +13,35 @@ </head> <body> - <h1>Whitelists in a separate policy are honored with `strict-dynamic` in the script-src directive.</h1> + <h1>Source expressions in a separate policy are honored with `strict-dynamic` in the script-src directive.</h1> <div id='log'></div> <script nonce='dummy'> async_test(function(t) { window.addEventListener('message', t.step_func(function(e) { - if (e.data === 'whitelisted-appendChild') { + if (e.data === 'allowed-appendChild') { t.done(); } })); window.addEventListener('securitypolicyviolation', t.step_func(function(violation) { - if (violation.blockedURI.split('?')[1] !== 'whitelisted-appendChild') { + if (violation.blockedURI.split('?')[1] !== 'allowed-appendChild') { return; } - assert_unreached('Script injected via `appendChild` is allowed with `strict-dynamic` + a nonce+whitelist double policy.'); + assert_unreached('Script injected via `appendChild` is permitted with `strict-dynamic` + a nonce+allowed double policy.'); })); var e = document.createElement('script'); - e.id = 'whitelisted-appendChild'; + e.id = 'allowed-appendChild'; e.src = 'simpleSourcedScript.js?' + e.id; e.onerror = t.unreached_func('Error should not be triggered.'); document.body.appendChild(e); - }, 'Script injected via `appendChild` is allowed with `strict-dynamic` + a nonce+whitelist double policy.'); + }, 'Script injected via `appendChild` is permitted with `strict-dynamic` + a nonce+allowed double policy.'); </script> <script nonce='dummy'> async_test(function(t) { window.addEventListener('securitypolicyviolation', t.step_func(function(violation) { - if (violation.blockedURI.split('?')[1] !== 'nonWhitelisted-appendChild') { + if (violation.blockedURI.split('?')[1] !== 'nonAllowed-appendChild') { return; } assert_equals(violation.effectiveDirective, 'script-src-elem'); @@ -50,11 +50,11 @@ })); var e = document.createElement('script'); - e.id = 'nonWhitelisted-appendChild'; + e.id = 'nonAllowed-appendChild'; e.src = '{{location[scheme]}}://{{domains[www2]}}:{{ports[http][0]}}/nonexisting.js?' + e.id; e.onload = t.unreached_func('OnLoad should not be triggered.'); document.body.appendChild(e); - }, 'Non-whitelisted script injected via `appendChild` is not allowed with `strict-dynamic` + a nonce+whitelist double policy.'); + }, 'Non-allowed script injected via `appendChild` is not permitted with `strict-dynamic` + a nonce+allowed double policy.'); </script> </body> diff --git a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_whitelist.sub.html.headers b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_source_expressions.html.headers index 5b4078efd37..5b4078efd37 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_whitelist.sub.html.headers +++ b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_double_policy_honor_source_expressions.html.headers diff --git a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_in_img-src.html b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_in_img-src.html index d640421cb74..29a2a59573e 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_in_img-src.html +++ b/tests/wpt/web-platform-tests/content-security-policy/script-src/script-src-strict_dynamic_in_img-src.html @@ -2,7 +2,7 @@ <html> <head> - <title>`strict-dynamic` does not drop whitelists in `img-src`.</title> + <title>`strict-dynamic` does not drop allowed source expressions in `img-src`.</title> <script src='/resources/testharness.js' nonce='dummy'></script> <script src='/resources/testharnessreport.js' nonce='dummy'></script> @@ -10,7 +10,7 @@ </head> <body> - <h1>`strict-dynamic` does not drop whitelists in `img-src`.</h1> + <h1>`strict-dynamic` does not drop allowed source expressions in `img-src`.</h1> <div id='log'></div> <script nonce='dummy'> @@ -20,12 +20,12 @@ async_test(function(t) { var e = document.createElement('img'); - e.id = 'whitelistedImage'; + e.id = 'allowedImage'; e.src = '/content-security-policy/support/pass.png'; e.onerror = t.unreached_func('Error should not be triggered.'); e.onload = t.step_func_done(); document.body.appendChild(e); - }, '`strict-dynamic` does not drop whitelists in `img-src`.'); + }, '`strict-dynamic` does not drop allowed source expressions in `img-src`.'); </script> </body> diff --git a/tests/wpt/web-platform-tests/content-security-policy/style-src/stylenonce-allowed.sub.html b/tests/wpt/web-platform-tests/content-security-policy/style-src/stylenonce-allowed.sub.html index e190b84e857..fcedc15ec6c 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/style-src/stylenonce-allowed.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/style-src/stylenonce-allowed.sub.html @@ -51,7 +51,7 @@ }); </script> - <p>Style correctly whitelisted via a 'nonce-*' expression in 'style-src' should be applied to the page.</p> + <p>Style correctly allowed via a 'nonce-*' expression in 'style-src' should be applied to the page.</p> <div id="log"></div> </body> diff --git a/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-child-fallback.sub.html b/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-child-fallback.sub.html index 9c37dfb6301..c16a9a543ec 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-child-fallback.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-child-fallback.sub.html @@ -4,6 +4,6 @@ <script src=/resources/testharness.js></script> <script src=/resources/testharnessreport.js></script> <script src="../support/testharness-helper.js"></script> -<!-- Ideally we would use "script-src 'none'" alone but we have to whitelist the actual script that spawns the workers, hence the nonce.--> +<!-- Ideally we would use "script-src 'none'" alone but we have to allow the actual script that spawns the workers, hence the nonce.--> <meta http-equiv="Content-Security-Policy" content="child-src 'self'; script-src 'none' 'nonce-foo'; default-src 'none'; "> -<script src="../support/dedicated-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin dedicated worker allowed by child-src 'self'."></script>
\ No newline at end of file +<script src="../support/dedicated-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin dedicated worker allowed by child-src 'self'."></script> diff --git a/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-self-fallback.sub.html b/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-self-fallback.sub.html index 06e79db0062..69e96473bc4 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-self-fallback.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/worker-src/dedicated-worker-src-self-fallback.sub.html @@ -4,6 +4,6 @@ <script src=/resources/testharness.js></script> <script src=/resources/testharnessreport.js></script> <script src="../support/testharness-helper.js"></script> -<!-- Ideally we would use "script-src 'none'" alone but we have to whitelist the actual script that spawns the workers, hence the nonce.--> +<!-- Ideally we would use "script-src 'none'" alone but we have to allow the actual script that spawns the workers, hence the nonce.--> <meta http-equiv="Content-Security-Policy" content="worker-src 'self'; child-src 'none'; script-src 'none' 'nonce-foo'; default-src 'none'; "> -<script src="../support/dedicated-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin dedicated worker allowed by worker-src 'self'."></script>
\ No newline at end of file +<script src="../support/dedicated-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin dedicated worker allowed by worker-src 'self'."></script> diff --git a/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-child-fallback.https.sub.html b/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-child-fallback.https.sub.html index 0053b1098aa..4d6f2f333af 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-child-fallback.https.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-child-fallback.https.sub.html @@ -4,6 +4,6 @@ <script src=/resources/testharness.js></script> <script src=/resources/testharnessreport.js></script> <script src="../support/testharness-helper.js"></script> -<!-- Ideally we would use "script-src 'none'" alone but we have to whitelist the actual script that spawns the workers, hence the nonce.--> +<!-- Ideally we would use "script-src 'none'" alone but we have to allow the actual script that spawns the workers, hence the nonce.--> <meta http-equiv="Content-Security-Policy" content="child-src 'self'; script-src 'none' 'nonce-foo'; default-src 'none'; "> -<script src="../support/service-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin service worker allowed by child-src 'self'."></script>
\ No newline at end of file +<script src="../support/service-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin service worker allowed by child-src 'self'."></script> diff --git a/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-self-fallback.https.sub.html b/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-self-fallback.https.sub.html index 58bc8cdb7a7..575911207e0 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-self-fallback.https.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/worker-src/service-worker-src-self-fallback.https.sub.html @@ -4,6 +4,6 @@ <script src=/resources/testharness.js></script> <script src=/resources/testharnessreport.js></script> <script src="../support/testharness-helper.js"></script> -<!-- Ideally we would use "script-src 'none'" alone but we have to whitelist the actual script that spawns the workers, hence the nonce.--> +<!-- Ideally we would use "script-src 'none'" alone but we have to allow the actual script that spawns the workers, hence the nonce.--> <meta http-equiv="Content-Security-Policy" content="worker-src 'self'; child-src 'none'; script-src 'none' 'nonce-foo'; default-src 'none'; "> -<script src="../support/service-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin service worker allowed by worker-src 'self'."></script>
\ No newline at end of file +<script src="../support/service-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin service worker allowed by worker-src 'self'."></script> diff --git a/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-child-fallback.sub.html b/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-child-fallback.sub.html index 53510852ef0..1e6a1df54b5 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-child-fallback.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-child-fallback.sub.html @@ -4,6 +4,6 @@ <script src=/resources/testharness.js></script> <script src=/resources/testharnessreport.js></script> <script src="../support/testharness-helper.js"></script> -<!-- Ideally we would use "script-src 'none'" alone but we have to whitelist the actual script that spawns the workers, hence the nonce.--> +<!-- Ideally we would use "script-src 'none'" alone but we have to allow the actual script that spawns the workers, hence the nonce.--> <meta http-equiv="Content-Security-Policy" content="child-src 'self'; script-src 'none' 'nonce-foo'; default-src 'none'; "> -<script src="../support/shared-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin shared worker allowed by child-src 'self'."></script>
\ No newline at end of file +<script src="../support/shared-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin shared worker allowed by child-src 'self'."></script> diff --git a/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-self-fallback.sub.html b/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-self-fallback.sub.html index 353a3a0d51b..dc8370bdbef 100644 --- a/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-self-fallback.sub.html +++ b/tests/wpt/web-platform-tests/content-security-policy/worker-src/shared-worker-src-self-fallback.sub.html @@ -4,6 +4,6 @@ <script src=/resources/testharness.js></script> <script src=/resources/testharnessreport.js></script> <script src="../support/testharness-helper.js"></script> -<!-- Ideally we would use "script-src 'none'" alone but we have to whitelist the actual script that spawns the workers, hence the nonce.--> +<!-- Ideally we would use "script-src 'none'" alone but we have to allow the actual script that spawns the workers, hence the nonce.--> <meta http-equiv="Content-Security-Policy" content="worker-src 'self'; child-src 'none'; script-src 'none' 'nonce-foo'; default-src 'none'; "> -<script src="../support/shared-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin shared worker allowed by worker-src 'self'."></script>
\ No newline at end of file +<script src="../support/shared-worker-helper.js" nonce="foo" id="foo" data-desc-fallback="Same-origin shared worker allowed by worker-src 'self'."></script> diff --git a/tests/wpt/web-platform-tests/cookie-store/cookieStore_delete_insecure.tentative.https.any.js b/tests/wpt/web-platform-tests/cookie-store/cookieStore_delete_insecure.tentative.https.any.js index 911e2fbac55..e97401a7cce 100644 --- a/tests/wpt/web-platform-tests/cookie-store/cookieStore_delete_insecure.tentative.https.any.js +++ b/tests/wpt/web-platform-tests/cookie-store/cookieStore_delete_insecure.tentative.https.any.js @@ -19,4 +19,4 @@ promise_test(async t => { await cookieStore.delete({ name: 'cookie-name' }); const cookie = await cookieStore.get('cookie-name'); assert_equals(cookie, null); -}, 'cookieStore.delete(options) can delete an insecure cookie');
\ No newline at end of file +}, 'cookieStore.delete(options) can delete an insecure cookie'); diff --git a/tests/wpt/web-platform-tests/cookie-store/cookieStore_get_delete_basic.tentative.https.any.js b/tests/wpt/web-platform-tests/cookie-store/cookieStore_get_delete_basic.tentative.https.any.js index fad175d8da7..d71afe2044c 100644 --- a/tests/wpt/web-platform-tests/cookie-store/cookieStore_get_delete_basic.tentative.https.any.js +++ b/tests/wpt/web-platform-tests/cookie-store/cookieStore_get_delete_basic.tentative.https.any.js @@ -11,4 +11,4 @@ promise_test(async testCase => { await cookieStore.delete('cookie-name'); const cookie = await cookieStore.get(); assert_equals(cookie, null); -}, 'cookieStore.get returns null for a cookie deleted by cookieStore.delete');
\ No newline at end of file +}, 'cookieStore.get returns null for a cookie deleted by cookieStore.delete'); diff --git a/tests/wpt/web-platform-tests/cookie-store/cookieStore_set_arguments.tentative.https.any.js b/tests/wpt/web-platform-tests/cookie-store/cookieStore_set_arguments.tentative.https.any.js index 6685f5fd3b7..5668b858be0 100644 --- a/tests/wpt/web-platform-tests/cookie-store/cookieStore_set_arguments.tentative.https.any.js +++ b/tests/wpt/web-platform-tests/cookie-store/cookieStore_set_arguments.tentative.https.any.js @@ -159,6 +159,19 @@ promise_test(async testCase => { promise_test(async testCase => { const currentUrl = new URL(self.location.href); const currentDomain = currentUrl.hostname; + + await promise_rejects_js(testCase, TypeError, cookieStore.set( + 'cookie-name', 'cookie-value', { domain: `.${currentDomain}` })); +}, 'cookieStore.set domain starts with "."'); + +promise_test(async testCase => { + await promise_rejects_js(testCase, TypeError, cookieStore.set( + 'cookie-name', 'cookie-value', { domain: 'example.com' })); +}, 'cookieStore.set with domain that is not equal current host'); + +promise_test(async testCase => { + const currentUrl = new URL(self.location.href); + const currentDomain = currentUrl.hostname; await cookieStore.delete({ name: 'cookie-name', domain: currentDomain }); await cookieStore.set( diff --git a/tests/wpt/web-platform-tests/css/css-flexbox/fixedpos-video-in-abspos-quirk-crash.html b/tests/wpt/web-platform-tests/css/css-flexbox/fixedpos-video-in-abspos-quirk-crash.html new file mode 100644 index 00000000000..80cae086ca7 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-flexbox/fixedpos-video-in-abspos-quirk-crash.html @@ -0,0 +1,13 @@ +<!-- Quirks mode needed --> +<title>CSS Flexbox: fixed positioned video in absolute positioned on quirks mode</title> +<link rel="help" href="https://drafts.csswg.org/css-flexbox/#flex-containers"> +<link rel="help" href="https://drafts.csswg.org/css-sizing-3/#percentage-sizing"> +<link rel="help" href="https://crbug.com/841276"> +<meta name="assert" content="This test ensures that a video works with fixed position in absolute position on quirks mode."> +<div style="position:absolute;"> + <div> + <!-- Video element may work with shadow DOM using flex for media controls. + This is mostly useful for browsers that use flex inside of video.--> + <video style="position:fixed;"></video> + </div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-001-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-001-ref.html new file mode 100644 index 00000000000..c85fd77ef91 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-001-ref.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + display: inline-block; + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.area { display: inline-block; } +.area:nth-child(1) { width: 60px; } +.area:nth-child(2) { width: 60px; } +.area:nth-child(3) { width: 75px; } +.area:nth-child(4) { width: 100px; } +.verticalLR.area, .verticalRL.area { width: auto; } +.verticalLR > .area:nth-child(1), .verticalRL > .area:nth-child(1) { height: 60px; } +.verticalLR > .area:nth-child(2), .verticalRL > .area:nth-child(2) { height: 60px; } +.verticalLR > .area:nth-child(3), .verticalRL > .area:nth-child(3) { height: 75px; } +.verticalLR > .area:nth-child(4), .verticalRL > .area:nth-child(4) { height: 100px; } +.block { height: 125px; } +.block.verticalLR, .block.verticalRL { + width: 125px; + height: auto; +} +</style> + +<p>1x4 with parallel items.</p> +<div class="block"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block"><div class="area"><div class="item extraBottomPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> + +<br clear="all"> + +<div class="block verticalLR"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block verticalLR"><div class="area"><div class="item extraLeftPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block verticalRL"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block verticalRL"><div class="area"><div class="item extraLeftPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-001.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-001.html new file mode 100644 index 00000000000..2473bb5d4fc --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-001.html @@ -0,0 +1,50 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-001-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. The 'align-self' property (orthogonal to the shared context) aligns all items along the baseline-axis using the row-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.grid { grid: 125px / 60px 60px 75px 100px; } +</style> + +<p>1x4 with parallel items.</p> +<div class="block grid contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid contentStart justifyItemsStart alignItemsBaseline"><div class="item extraBottomPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> + +<br clear="all"> + +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item extraLeftPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item extraLeftPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-b-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-b-ref.html new file mode 100644 index 00000000000..460a4537eb7 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-b-ref.html @@ -0,0 +1,41 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 175px; + height: 300px; + font-family: Ahem; +} +.block1 > :nth-child(1) { font-size:24px; } +.block1 > :nth-child(2) { font-size:32px; } +.block2 > :nth-child(1) { font-size:48px; } +.block2 > :nth-child(2) { font-size:64px; } +.item { + display: inline-block; + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.area { display: inline-block; } +.block1 > .area:nth-child(1) { height: 60px; } +.block1 > .area:nth-child(2) { height: 60px; } +.block2 > .area:nth-child(1) { height: 75px; } +.block2 > .area:nth-child(2) { height: 100px; } +.block1 { float: left; } +.block2 { float: left; } +</style> + +<p>4x1 with orthogonal items, but opposite block-flow direction.</p> +<div class="block verticalLR"><div class="block1"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div><div class="block2 verticalRL"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div></div> +<div class="block verticalLR"><div class="block1"><div class="area"><div class="item extraLeftPadding">É</div></div><div class="area"><div class="item extraRightPadding">É</div></div></div><div class="block2 verticalRL"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-b.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-b.html new file mode 100644 index 00000000000..7d9ebecb8ca --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-b.html @@ -0,0 +1,46 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-002-b-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. We have 2 baseline-sharing groups. The 'justify-self' property (orthogonal to the shared context) aligns items in each group along the baseline-axis using the column-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 175px; + height: 300px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.column { grid-auto-flow: row; } +.grid { grid: 60px 60px 75px 100px / 125px; } +</style> + +<p>4x1 with orthogonal items, but opposite block-flow direction.</p> +<div class="block grid contentStart itemsBaseline"><div class="item verticalLR">É</div><div class="item verticalLR">É</div><div class="item verticalRL">É</div><div class="item verticalRL">É</div></div> +<div class="block grid contentStart itemsBaseline"><div class="item verticalLR extraLeftPadding">É</div><div class="item verticalLR extraRightPadding">É</div><div class="item verticalRL">É</div><div class="item verticalRL">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-ref.html new file mode 100644 index 00000000000..9c2f6e45218 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002-ref.html @@ -0,0 +1,42 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 175px; + font-family: Ahem; +} +.block1 > :nth-child(1) { font-size:24px; } +.block1 > :nth-child(2) { font-size:32px; } +.block2 > :nth-child(1) { font-size:48px; } +.block2 > :nth-child(2) { font-size:64px; } +.item { + display: inline-block; + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.area { display: inline-block; } +.block1 > .area:nth-child(1) { height: 60px; } +.block1 > .area:nth-child(2) { height: 60px; } +.block2 > .area:nth-child(1) { height: 75px; } +.block2 > .area:nth-child(2) { height: 100px; } +.block1 { float: left; } +.block2 { float: left; } +</style> + +<p>1x4 with parallel items, but opposite block-flow direction.</p> +<div class="block verticalLR"><div class="block1"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div><div class="block2 verticalRL"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div></div> +<div class="block verticalLR"><div class="block1"><div class="area"><div class="item extraLeftPadding">É</div></div><div class="area"><div class="item">É</div></div></div><div class="block2 verticalRL"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div></div> +<div class="block verticalRL"><div class="block1"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div><div class="block2 verticalLR"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div></div> +<div class="block verticalRL"><div class="block1"><div class="area"><div class="item extraRightPadding">É</div></div><div class="area"><div class="item">É</div></div></div><div class="block2 verticalLR"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002.html new file mode 100644 index 00000000000..700fd26097e --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-002.html @@ -0,0 +1,45 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-002-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. We have 2 baseline-sharing groups. The 'align-self' property (orthogonal to the shared context) aligns items in each group along the baseline-axis using the row-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.grid { grid: 175px / 60px 60px 75px 100px; } +</style> + +<p>1x4 with parallel items, but opposite block-flow direction.</p> +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item">É</div><div class="item verticalRL">É</div><div class="item verticalRL">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item extraLeftPadding">É</div><div class="item">É</div><div class="item verticalRL">É</div><div class="item verticalRL">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item extraRightPadding">É</div><div class="item">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-003-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-003-ref.html new file mode 100644 index 00000000000..cd097c1d48a --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-003-ref.html @@ -0,0 +1,58 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.area:nth-child(1) { width: 70px; } +.area:nth-child(2) { width: 80px; } +.area:nth-child(3) { width: 100px; } +.area:nth-child(4) { width: 125px; } +.area { display: inline-block; } +.block.verticalLR > .area { float: left; } +.verticalLR > .area, .verticalRL > .area { width: auto; } +.verticalLR > .area:nth-child(1), .verticalRL > .area:nth-child(1) { height: 70px; } +.verticalLR > .area:nth-child(2), .verticalRL > .area:nth-child(2) { height: 80px; } +.verticalLR > .area:nth-child(3), .verticalRL > .area:nth-child(3) { height: 100px; } +.verticalLR > .area:nth-child(4), .verticalRL > .area:nth-child(4) { height: 125px; } +.block { + width: 375px; + height: 100px; +} +.block.verticalLR, .block.verticalRL { + width: 125px; + height: auto; +} +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block"><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div></div> +<div class="block"><div class="area verticalLR"><div class="item extraBottomPadding">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div></div> + +<br clear="all"> + +<div class="block verticalLR"><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block verticalLR"><div class="area horizontalTB"><div class="item extraLeftPadding">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item ">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block verticalRL"><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block verticalRL"><div class="area horizontalTB"><div class="item extraRightPadding">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-003.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-003.html new file mode 100644 index 00000000000..2372ac19318 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-003.html @@ -0,0 +1,55 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-003-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that items orthogonal to the baseline-axis will use a synthesized baseline (border-box 'under' edge). All items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. The 'align-self' property (orthogonal to the shared context) aligns all items along the baseline-axis using the row-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.grid { grid: 100px / 70px 80px 100px 125px; } +.block.verticalLR, .block.verticalRL { + width: 125px; +} +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block grid contentStart justifyItemsStart alignItemsBaseline"><div class="item verticalLR">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div></div> +<div class="block grid contentStart justifyItemsStart alignItemsBaseline"><div class="item verticalLR extraBottomPadding">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div></div> + +<br clear="all"> + +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item horizontalTB extraLeftPadding">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> + +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item horizontalTB extraRightPadding">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-004-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-004-ref.html new file mode 100644 index 00000000000..d589acb3742 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-004-ref.html @@ -0,0 +1,58 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + display: inline-block; + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.area.verticalLR > .item { margin: 10px 6px 0px 12px; } +.area.horizontalTB > .item { margin: 10px 6px 4px 0px; } +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.area { display: inline-block; } +.area:nth-child(1) { width: 60px; } +.area:nth-child(2) { width: 75px; } +.area:nth-child(3) { width: 75px; } +.area:nth-child(4) { width: 125px; } +.verticalLR > .area, .verticalRL > .area { width: auto; } +.verticalLR > .area:nth-child(1), .verticalRL > .area:nth-child(1) { height: 60px; } +.verticalLR > .area:nth-child(2), .verticalRL > .area:nth-child(2) { height: 75px; } +.verticalLR > .area:nth-child(3), .verticalRL > .area:nth-child(3) { height: 75px; } +.verticalLR > .area:nth-child(4), .verticalRL > .area:nth-child(4) { height: 125px; } +.block { height: 125px; } +.block.verticalLR, .block.verticalRL { + width: 150px; + height: auto; +} +</style> + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block"><div class="area"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div></div> +<div class="block"><div class="area"><div class="item extraBottomPadding">É</div></div><div class="area verticalLR"><div class="item extraTopPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area verticalLR top"><div class="item">É</div></div></div> + +<br clear="all"> + +<div class="block verticalLR"><div class="area"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block verticalLR"><div class="area"><div class="item extraLeftPadding">É</div></div><div class="area horizontalTB"><div class="item extraRightPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block verticalRL"><div class="area"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block verticalRL"><div class="area"><div class="item extraRightPadding">É</div></div><div class="area horizontalTB"><div class="item extraLeftPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-004.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-004.html new file mode 100644 index 00000000000..c7f49bf24af --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-004.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-004-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that items orthogonal to the baseline-axis will use a synthesized baseline (border-box 'under' edge). All items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. The 'align-self' property (orthogonal to the shared context) aligns all the items along the baseline-axis using the row-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.grid { grid: 125px / 60px 75px 75px 125px; } +.grid.verticalLR, .grid.verticalRL { grid-template-rows: 150px; } +</style> + + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block grid contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item verticalLR">É</div><div class="item">É</div><div class="item verticalLR">É</div></div> +<div class="block grid contentStart justifyItemsStart alignItemsBaseline"><div class="item extraBottomPadding">É</div><div class="item verticalLR extraTopPadding">É</div><div class="item">É</div><div class="item verticalLR">É</div></div> + +<br clear="all"> + +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item horizontalTB">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsStart alignItemsBaseline"><div class="item extraLeftPadding">É</div><div class="item horizontalTB extraRightPadding">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item">É</div><div class="item horizontalTB">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsStart alignItemsBaseline"><div class="item extraRightPadding">É</div><div class="item horizontalTB extraLeftPadding">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-005-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-005-ref.html new file mode 100644 index 00000000000..75a366fc409 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-005-ref.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + display: inline-block; + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.area { display: inline-block; } +.area:nth-child(1) { width: 60px; } +.area:nth-child(2) { width: 60px; } +.area:nth-child(3) { width: 75px; } +.area:nth-child(4) { width: 100px; } +.verticalLR.area, .verticalRL.area { width: auto; } +.verticalLR > .area:nth-child(1), .verticalRL > .area:nth-child(1) { height: 60px; } +.verticalLR > .area:nth-child(2), .verticalRL > .area:nth-child(2) { height: 60px; } +.verticalLR > .area:nth-child(3), .verticalRL > .area:nth-child(3) { height: 75px; } +.verticalLR > .area:nth-child(4), .verticalRL > .area:nth-child(4) { height: 100px; } +.block { height: 140px; } +.block.verticalLR, .block.verticalRL { + width: 140px; + height: auto; +} +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block verticalLR"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block verticalLR"><div class="area"><div class="item extraLeftPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block"><div class="area"><div class="item extraBottomPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> + +<br clear="all"> + +<div style="direction: rtl;" class="block"><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div style="direction: rtl;" class="block"><div class="area"><div class="item extraBottomPadding">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-005.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-005.html new file mode 100644 index 00000000000..3bfa2d20799 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-005.html @@ -0,0 +1,50 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-005-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context. All items share 'first-column' Baseline Context. The 'justify-self' property (orthogonal to the shared context) aligns all items along the baseline-axis using the column-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.grid { grid: 60px 60px 75px 100px / 140px; } +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block grid contentStart justifyItemsBaseline alignItemsStart"><div class="item verticalLR">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div></div> +<div class="block grid contentStart justifyItemsBaseline alignItemsStart"><div class="item verticalLR extraLeftPadding">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div><div class="item verticalLR">É</div></div> +<div class="block grid contentStart verticalLR justifyItemsBaseline alignItemsStart"><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid contentStart verticalLR justifyItemsBaseline alignItemsStart"><div class="item horizontalTB extraBottomPadding">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> + +<br clear="all"> + +<div class="block grid contentStart verticalRL justifyItemsBaseline alignItemsStart"><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid contentStart verticalRL justifyItemsBaseline alignItemsStart"><div class="item horizontalTB extraBottomPadding">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-006-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-006-ref.html new file mode 100644 index 00000000000..610b2ad0a11 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-006-ref.html @@ -0,0 +1,52 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.extraRightPadding { padding-right: 30px; } +.area { display: inline-block; } +.block.verticalLR > .area { float: left; } +.area:nth-child(1) { width: 65px; } +.area:nth-child(2) { width: 75px; } +.area:nth-child(3) { width: 100px; } +.area:nth-child(4) { width: 125px; } +.verticalLR > .area, .verticalRL > .area { width: auto; } +.verticalLR > .area:nth-child(1), .verticalRL > .area:nth-child(1) { height: 65px; } +.verticalLR > .area:nth-child(2), .verticalRL > .area:nth-child(2) { height: 75px; } +.verticalLR > .area:nth-child(3), .verticalRL > .area:nth-child(3) { height: 100px; } +.verticalLR > .area:nth-child(4), .verticalRL > .area:nth-child(4) { height: 125px; } +.block { height: 100px; } +.block.verticalLR, .block.verticalRL { + width: 100px; + height: auto; +} +</style> + +<p>4x1 with parallel items.</p> +<div class="block verticalLR"><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block verticalLR"><div class="area horizontalTB"><div class="item extraRightPadding">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div></div> +<div class="block"><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div></div> +<div class="block"><div class="area verticalLR"><div class="item extraTopPadding">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div></div> +<div class="block directionRTL"><div class="area verticalRL"><div class="item">É</div></div><div class="area verticalRL"><div class="item">É</div></div><div class="area verticalRL"><div class="item">É</div></div><div class="area verticalRL"><div class="item">É</div></div></div> +<div class="block directionRTL"><div class="area verticalRL"><div class="item extraBottomPadding">É</div></div><div class="area verticalRL"><div class="item">É</div></div><div class="area verticalRL"><div class="item">É</div></div><div class="area verticalRL"><div class="item">É</div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-006.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-006.html new file mode 100644 index 00000000000..34edced2b43 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-006.html @@ -0,0 +1,48 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-006-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that items orthogonal to the baseline-axis will use a synthesized baseline (border-box 'under' edge). No item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. The 'justify-self' property (orthogonal to the shared context) aligns all items along the baseline-axis using the column-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.extraRightPadding { padding-right: 30px; } +.grid { grid: 65px 75px 100px 125px / 100px; } +</style> + +<p>4x1 with parallel items.</p> +<div class="block grid contentStart justifyItemsBaseline alignItemsStart"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid contentStart justifyItemsBaseline alignItemsStart"><div class="item extraRightPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsBaseline alignItemsStart"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsBaseline alignItemsStart"><div class="item extraTopPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsBaseline alignItemsStart"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsBaseline alignItemsStart"><div class="item extraBottomPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-007-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-007-ref.html new file mode 100644 index 00000000000..59a0e339598 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-007-ref.html @@ -0,0 +1,58 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + display: inline-block; + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.area.verticalLR > .item, .area.verticalRL > .item { margin: 10px 6px 0px 12px; } +.area.horizontalTB > .item { margin: 10px 6px 4px 0px; } +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.area { display: inline-block; } +.area:nth-child(1) { width: 65px; } +.area:nth-child(2) { width: 60px; } +.area:nth-child(3) { width: 100px; } +.area:nth-child(4) { width: 100px; } +.verticalLR > .area, .verticalRL > .area { width: auto; } +.verticalLR > .area:nth-child(1), .verticalRL > .area:nth-child(1) { height: 65px; } +.verticalLR > .area:nth-child(2), .verticalRL > .area:nth-child(2) { height: 60px; } +.verticalLR > .area:nth-child(3), .verticalRL > .area:nth-child(3) { height: 100px; } +.verticalLR > .area:nth-child(4), .verticalRL > .area:nth-child(4) { height: 100px; } +.block { height: 125px; } +.block.verticalLR, .block.verticalRL { + width: 150px; + height: auto; +} +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block verticalLR"><div class="area horizontalTB"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block verticalLR"><div class="area horizontalTB"><div class="item extraLeftPadding">É</div></div><div class="area"><div class="item extraRightPadding">É</div></div><div class="area horizontalTB"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block"><div class="area verticalLR"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block"><div class="area verticalLR"><div class="item extraBottomPadding">É</div></div><div class="area"><div class="item extraTopPadding">É</div></div><div class="area verticalLR"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> + +<br clear="all"> + +<div class="block directionRTL"><div class="area verticalRL"><div class="item">É</div></div><div class="area"><div class="item">É</div></div><div class="area verticalRL"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> +<div class="block directionRTL"><div class="area verticalRL"><div class="item extraBottomPadding">É</div></div><div class="area"><div class="item extraTopPadding">É</div></div><div class="area verticalRL"><div class="item">É</div></div><div class="area"><div class="item">É</div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-007.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-007.html new file mode 100644 index 00000000000..e0966bb6e64 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-007.html @@ -0,0 +1,53 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-007-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that items orthogonal to the baseline-axis will use a synthesized baseline (border-box 'under' edge). No item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. The 'justify-self' property (orthogonal to the shared context) aligns all items along the baseline-axis using the column-like baseline." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.grid { grid: 65px 60px 100px 100px / 150px; } +.grid.verticalLR, .grid.verticalRL { grid-template-columns: 125px; } +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block grid contentStart justifyItemsBaseline alignItemsStart"><div class="item">É</div><div class="item verticalLR">É</div><div class="item">É</div><div class="item verticalLR">É</div></div> +<div class="block grid contentStart justifyItemsBaseline alignItemsStart"><div class="item extraLeftPadding">É</div><div class="item verticalLR extraRightPadding">É</div><div class="item horizontalTB">É</div><div class="item verticalLR">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsBaseline alignItemsStart"><div class="item">É</div><div class="item horizontalTB">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid verticalLR contentStart justifyItemsBaseline alignItemsStart"><div class="item extraBottomPadding">É</div><div class="item horizontalTB extraTopPadding">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> + +<br clear="all"> + +<div class="block grid verticalRL contentStart justifyItemsBaseline alignItemsStart"><div class="item">É</div><div class="item horizontalTB">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> +<div class="block grid verticalRL contentStart justifyItemsBaseline alignItemsStart"><div class="item extraBottomPadding">É</div><div class="item horizontalTB extraTopPadding">É</div><div class="item">É</div><div class="item horizontalTB">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-001-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-001-ref.html new file mode 100644 index 00000000000..1b8130d7b89 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-001-ref.html @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.item { display: inline-block; } +</style> + +<p>1x4 with parallel items.</p> +<div class="block"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div class="item"> +<div class="block"><div class="item extraBottomPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-001.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-001.html new file mode 100644 index 00000000000..556009dfde7 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-001.html @@ -0,0 +1,52 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (horizontal)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-horiz-001-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. Items participate in both, column and row baseline, but since they only share a row-like Baseline Context only 'aling-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel items.</p> +<div class="block grid row contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> +<div class="block grid row contentStart itemsBaseline"> + <div class="item extraBottomPadding">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-002-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-002-ref.html new file mode 100644 index 00000000000..a99656f94e2 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-002-ref.html @@ -0,0 +1,42 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.top { vertical-align: top; } +.item { display: inline-block; } +.item.verticalLR, .item.verticalRL { margin: 10px 6px 4px 12px; } +.item.horizontalTB { margin: 10px 6px 4px 0px; } + +</style> + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block"><div class="item">É</div><div class="item verticalLR top">É</div><div class="item">É</div><div class="item verticalLR top">É</div></div> +<div class="block"><div class="item extraBottomPadding">É</div><div class="item verticalLR extraTopPadding top">É</div><div class="item">É</div><div class="item verticalLR top">É</div></div> + +<br clear="all"> + +<div class="block"><div class="item">É</div><div class="item verticalRL top">É</div><div class="item">É</div><div class="item verticalRL top">É</div></div> +<div class="block"><div class="item extraBottomPadding">É</div><div class="item verticalRL extraTopPadding top">É</div><div class="item">É</div><div class="item verticalRL top">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-002.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-002.html new file mode 100644 index 00000000000..c196cd35c51 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-002.html @@ -0,0 +1,69 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (horizontal)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-horiz-002-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. Only the parallel items participate in baseline alignment in the row-like Baseline Context; since no item shares column-like Baseline Context, only 'align-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block grid row contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item verticalLR">É</div> + <div class="item">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid row contentStart itemsBaseline"> + <div class="item extraBottomPadding">É</div> + <div class="item verticalLR extraTopPadding">É</div> + <div class="item">É</div> + <div class="item verticalLR">É</div> +</div> + +<br clear="all"> + +<div class="block grid row contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item verticalRL">É</div> + <div class="item">É</div> + <div class="item verticalRL">É</div> +</div> +<div class="block grid row contentStart itemsBaseline"> + <div class="item extraBottomPadding">É</div> + <div class="item verticalRL extraTopPadding">É</div> + <div class="item">É</div> + <div class="item verticalRL">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-003-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-003-ref.html new file mode 100644 index 00000000000..58f68d5b258 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-003-ref.html @@ -0,0 +1,37 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 375px; + height: 100px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.top { vertical-align: top; } +.item { display: inline-block; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block"><div class="item verticalLR top">É</div><div class="item verticalLR top">É</div><div class="item verticalLR top">É</div><div class="item verticalLR top">É</div></div> +<div class="block" ><div class="item verticalLR extraTopPadding top">É</div><div class="item verticalLR top">É</div><div class="item verticalLR extraBottomPadding top">É</div><div class="item verticalLR top">É</div></div> +<div class="block"><div class="item verticalRL top">É</div><div class="item verticalRL top">É</div><div class="item verticalRL top">É</div><div class="item verticalRL top">É</div></div> +<div class="block" ><div class="item verticalRL extraTopPadding top">É</div><div class="item verticalRL top">É</div><div class="item verticalRL extraBottomPadding top">É</div><div class="item verticalRL top">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-003.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-003.html new file mode 100644 index 00000000000..287cb80fd58 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-003.html @@ -0,0 +1,67 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (horizontal)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-horiz-003-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. Orthogonal items don't participate in baseline alignment in the row-like Baseline Context; since no item shares column-like Baseline Context, neither 'aling-self' or 'justify-self' apply." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 375px; + height: 100px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block grid row contentStart itemsBaseline"> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid row contentStart itemsBaseline"> + <div class="item verticalLR extraTopPadding">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR extraBottomPadding">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid row contentStart itemsBaseline"> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> +</div> +<div class="block grid row contentStart itemsBaseline"> + <div class="item verticalRL extraTopPadding">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL extraBottomPadding">É</div> + <div class="item verticalRL">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-004-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-004-ref.html new file mode 100644 index 00000000000..be610d4f7f2 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-004-ref.html @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 150px; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraRightPadding { padding-right: 30px; } +.extraLeftPadding { padding-left: 30px; } +.item { display: inline; } +.left { vertical-align: bottom; } +</style> + +<p>4x1 with parallel items.</p> +<div class="block verticalLR"><div class="item horizontalTB left">É</div><div class="item horizontalTB left">É</div><div class="item horizontalTB left">É</div><div class="item horizontalTB left">É</div></div> +<div class="block verticalLR"><div class="item horizontalTB extraRightPadding left">É</div><div class="item horizontalTB left">É</div><div class="item horizontalTB extraLeftPadding left">É</div><div class="item horizontalTB left">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-004.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-004.html new file mode 100644 index 00000000000..673c9ff2082 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-004.html @@ -0,0 +1,55 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (horizontal)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-horiz-004-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. All the items are orthogonal to the column-axis, so they don't participate in the column-like Baseline Context; since no items shares row-like Baseline context, neither 'justify-self' or 'align-self' should apply." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 150px; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraRightPadding { padding-right: 30px; } +.extraLeftPadding { padding-left: 30px; } +.column { grid-auto-flow: row; } +</style> + +<p>4x1 with parallel items.</p> +<div class="block grid column contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item extraRightPadding">É</div> + <div class="item">É</div> + <div class="item extraLeftPadding">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-005-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-005-ref.html new file mode 100644 index 00000000000..5e2f6da9d5f --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-005-ref.html @@ -0,0 +1,38 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + position: relative; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.inline { display: inline-block; } +.item { display: inline-block; } +.bottom { vertical-align: bottom; } +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block verticalLR"><div class="item horizontalTB bottom">É</div><div class="item">É</div><div class="item bottom horizontalTB">É</div><div class="item">É</div></div> +<div class="block verticalLR"><div class="item horizontalTB bottom extraRightPadding">É</div><div class="item extraLeftPadding">É</div><div class="item bottom horizontalTB">É</div><div class="item">É</div></div> +<div class="block verticalRL"><div class="item horizontalTB bottom">É</div><div class="item">É</div><div class="item bottom horizontalTB">É</div><div class="item">É</div></div> +<div class="block verticalRL"><div class="item horizontalTB bottom extraRightPadding">É</div><div class="item extraLeftPadding">É</div><div class="item bottom horizontalTB">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-005.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-005.html new file mode 100644 index 00000000000..f816e893ca2 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-005.html @@ -0,0 +1,66 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (horizontal)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-horiz-005-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. Only the parallel items participate in baseline alignment in the column-like Baseline Context; since no item shares row-like Baseline Context, only 'justify-self' (row baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.column { grid-auto-flow: row } +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block grid column contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item verticalLR">É</div> + <div class="item">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item extraRightPadding">É</div> + <div class="item verticalLR extraLeftPadding">É</div> + <div class="item">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item verticalRL">É</div> + <div class="item">É</div> + <div class="item verticalRL">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item extraRightPadding">É</div> + <div class="item verticalRL extraLeftPadding">É</div> + <div class="item">É</div> + <div class="item verticalRL">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-006-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-006-ref.html new file mode 100644 index 00000000000..6053b38a6fd --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-006-ref.html @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { display: inline-block; } +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block verticalLR"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block verticalLR"><div class="item extraLeftPadding">É</div><div class="item extraRightPadding">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block verticalRL"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block verticalRL"><div class="item extraLeftPadding">É</div><div class="item extraRightPadding">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-006.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-006.html new file mode 100644 index 00000000000..c034040b5fd --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-006.html @@ -0,0 +1,66 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (horizontal)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-horiz-006-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. Items participate in both, column and row baseline, but since they only share a column-like Baseline Context only 'justify-self' (row baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.column { grid-auto-flow: row } +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block grid column contentStart itemsBaseline"> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item verticalLR extraLeftPadding">É</div> + <div class="item verticalLR extraRightPadding ">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item verticalRL extraLeftPadding">É</div> + <div class="item verticalRL extraRightPadding ">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-007-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-007-ref.html new file mode 100644 index 00000000000..e92a90ef269 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-007-ref.html @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 200px; + height: 300px; + font-family: Ahem; +} +.block1 > :nth-child(1) { font-size:24px; } +.block1 > :nth-child(2) { font-size:32px; } +.block2 > :nth-child(1) { font-size:48px; } +.block2 > :nth-child(2) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { display: inline-block; } +.block1, .block2 { float: left; } +</style> + +<p>4x1 with orthogonal items, but opposite block-flow direction.</p> +<div class="block verticalLR"><div class="block1"><div class="item">É</div><div class="item">É</div></div><div class="block2 verticalRL"><div class="item">É</div><div class="item">É</div></div></div></div> +<div class="block verticalLR"><div class="block1"><div class="item extraRightPadding">É</div><div class="item extraLeftPadding">É</div></div><div class="block2 verticalRL"><div class="item">É</div><div class="item">É</div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-007.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-007.html new file mode 100644 index 00000000000..60185142427 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-horiz-007.html @@ -0,0 +1,55 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (horizontal)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-horiz-007-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. We have 2 baseline-sharing groups. Items participate in both, column and row baseline, but since they only share a column-like Baseline Context only 'justify-self' (row baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 200px; + height: 300px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.column { grid-auto-flow: row } +</style> + +<p>4x1 with orthogonal items, but opposite block-flow direction.</p> +<div class="block grid column contentStart itemsBaseline"> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> +</div> +<div class="block grid column contentStart itemsBaseline"> + <div class="item verticalLR extraRightPadding">É</div> + <div class="item verticalLR extraLeftPadding">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-001-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-001-ref.html new file mode 100644 index 00000000000..cf19544be84 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-001-ref.html @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.item { display: inline-block; } +</style> + +<p>1x4 with parallel items.</p> +<div class="block verticalLR"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block verticalLR"><div class="item extraLeftPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-001.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-001.html new file mode 100644 index 00000000000..801474df57c --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-001.html @@ -0,0 +1,52 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-lr)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-lr-001-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. Items participate in both, column and row baseline, but since they only share a row-like Baseline Context only 'aling-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel items.</p> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item extraLeftPadding">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-002-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-002-ref.html new file mode 100644 index 00000000000..1aef905f16b --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-002-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { display: inline-block; } +.bottom { vertical-align: bottom; } +</style> + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block verticalLR"><div class="item bottom horizontalTB">É</div><div class="item">É</div><div class="item bottom horizontalTB">É</div><div class="item">É</div></div> +<div class="block verticalLR"><div class="item bottom horizontalTB extraLeftPadding">É</div><div class="item extraRightPadding">É</div><div class="item bottom horizontalTB">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-002.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-002.html new file mode 100644 index 00000000000..6dd235a7b6f --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-002.html @@ -0,0 +1,54 @@ + <!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-lr)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-lr-002-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. Only the parallel items participate in baseline alignment in the row-like Baseline Context; since no item shares column-like Baseline Context, only 'aling-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item horizontalTB">É</div> + <div class="item">É</div> + <div class="item horizontalTB">É</div> + <div class="item">É</div> +</div> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item horizontalTB extraLeftPadding">É</div> + <div class="item extraRightPadding">É</div> + <div class="item horizontalTB">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-003-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-003-ref.html new file mode 100644 index 00000000000..795926615fa --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-003-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 150px; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { float: left; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block verticalLR"><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> +<div class="block verticalLR"><div class="item horizontalTB extraLeftPadding">É</div><div class="item horizontalTB extraRightPadding">É</div><div class="item horizontalTB">É</div><div class="item horizontalTB">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-003.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-003.html new file mode 100644 index 00000000000..18f581620d6 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-003.html @@ -0,0 +1,55 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-lr)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-lr-003-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. All the items are orthogonal to the row-axis, so they don't participate in the row-like Baseline Context; since no items shares column-like Baseline context, neither 'justify-self' or 'align-self' should apply." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 150px; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item horizontalTB extraLeftPadding">É</div> + <div class="item horizontalTB extraRightPadding">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-004-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-004-ref.html new file mode 100644 index 00000000000..cd6569ffbfd --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-004-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + height: 100px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.item { display: inline-block; } +.top { vertical-align: top; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block"><div class="item top verticalLR">É</div><div class="item top verticalLR">É</div><div class="item top verticalLR">É</div><div class="item top verticalLR">É</div></div> +<div class="block"><div class="item top verticalLR extraTopPadding">É</div><div class="item top verticalLR">É</div><div class="item top verticalLR">É</div><div class="item top verticalLR">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-004.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-004.html new file mode 100644 index 00000000000..1f2e3860b06 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-004.html @@ -0,0 +1,54 @@ + <!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-lr)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-lr-004-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. Orthogonal items don't participate in baseline alignment in the row-like Baseline Context; since no item shares column-like Baseline Context, neither 'aling-self' or 'justify-self' apply." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + height: 100px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block grid column verticalLR contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> +<div class="block grid column verticalLR contentStart itemsBaseline"> + <div class="item extraTopPadding">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-005-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-005-ref.html new file mode 100644 index 00000000000..571a77d3431 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-005-ref.html @@ -0,0 +1,36 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.item { display: inline-block; } +.item.verticalLR, .item.verticalRL { margin: 10px 6px 0px 12px; } +.item.horizontalTB { margin: 10px 6px 4px 0px; } +.top { vertical-align: top; } +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block"><div class="item top verticalLR">É</div><div class="item">É</div><div class="item top verticalLR">É</div><div class="item">É</div></div> +<div class="block"><div class="item top verticalLR extraTopPadding">É</div><div class="item extraBottomPadding">É</div><div class="item top verticalLR">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-005.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-005.html new file mode 100644 index 00000000000..a27cb67898e --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-005.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-lr)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-lr-005-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. Only the parallel items participate in baseline alignment in the column-like Baseline Context; since no item shares row-like Baseline Context, only 'justify-self' (row baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.column { grid-auto-flow: row } +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block grid column verticalLR contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item horizontalTB">É</div> + <div class="item">É</div> + <div class="item horizontalTB">É</div> +</div> +<div class="block grid column verticalLR contentStart itemsBaseline"> + <div class="item extraTopPadding">É</div> + <div class="item horizontalTB extraBottomPadding">É</div> + <div class="item">É</div> + <div class="item horizontalTB">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-006-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-006-ref.html new file mode 100644 index 00000000000..51c5f77da35 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-006-ref.html @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.item { display: inline-block; } +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block"><div class="item extraBottomPadding">É</div><div class="item extraTopPadding">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-006.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-006.html new file mode 100644 index 00000000000..654c17cd9e8 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-006.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-lr)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-lr-006-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. Items participate in both, column and row baseline, but since they only share a column-like Baseline Context only 'justify-self' (row baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.column { grid-auto-flow: row } +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block grid column verticalLR contentStart itemsBaseline"> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> +<div class="block grid column verticalLR contentStart itemsBaseline"> + <div class="item horizontalTB extraBottomPadding">É</div> + <div class="item horizontalTB extraTopPadding">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-007-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-007-ref.html new file mode 100644 index 00000000000..fe00a5f5a2e --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-007-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 200px; + font-family: Ahem; +} +.block1 > :nth-child(1) { font-size:24px; } +.block1 > :nth-child(2) { font-size:32px; } +.block2 > :nth-child(1) { font-size:48px; } +.block2 > :nth-child(2) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { display: inline-block; } +.block1, .block2 { float: left; } +</style> + +<p>1x4 with parallel items, but opposite block-flow direction.</p> +<div class="block verticalLR"><div class="block1"><div class="item">É</div><div class="item">É</div></div><div class="block2 verticalRL"><div class="item">É</div><div class="item">É</div></div></div> +<div class="block verticalLR"><div class="block1"><div class="item extraLeftPadding">É</div><div class="item extraRightPadding">É</div></div><div class="block2 verticalRL"><div class="item">É</div><div class="item">É</div></div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-007.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-007.html new file mode 100644 index 00000000000..ae7b6bf36ea --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-lr-007.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-lr)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-lr-007-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. We have 2 baseline-sharing groups. Items participate in both, column and row baseline, but since they only share a row-like Baseline Context only 'align-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 200px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel items, but opposite block-flow direction.</p> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> +</div> +<div class="block grid row verticalLR contentStart itemsBaseline"> + <div class="item extraLeftPadding">É</div> + <div class="item extraRightPadding">É</div> + <div class="item verticalRL">É</div> + <div class="item verticalRL">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-001-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-001-ref.html new file mode 100644 index 00000000000..02d3feb1267 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-001-ref.html @@ -0,0 +1,31 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.item { display: inline-block; } +</style> + +<p>1x4 with parallel items.</p> +<div class="block verticalRL"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block verticalRL"><div class="item extraLeftPadding">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-001.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-001.html new file mode 100644 index 00000000000..af7ca16d634 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-001.html @@ -0,0 +1,52 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-rl)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-rl-001-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. Items participate in both, column and row baseline, but since they only share a row-like Baseline Context only 'aling-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel items.</p> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item extraLeftPadding">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-002-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-002-ref.html new file mode 100644 index 00000000000..3be7c42ee5d --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-002-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { display: inline-block; } +.top { vertical-align: top; } +</style> + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block verticalRL"><div class="item top horizontalTB">É</div><div class="item">É</div><div class="item top horizontalTB">É</div><div class="item">É</div></div> +<div class="block verticalRL"><div class="item top horizontalTB extraLeftPadding">É</div><div class="item extraRightPadding">É</div><div class="item top horizontalTB">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-002.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-002.html new file mode 100644 index 00000000000..9aa00a71147 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-002.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-rl)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-rl-002-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context. No item shares any column-like Baseline Context. Only the parallel items participate in baseline alignment in the row-like Baseline Context; since no item shares column-like Baseline Context, only 'aling-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel and orthogonal items.</p> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item horizontalTB">É</div> + <div class="item">É</div> + <div class="item horizontalTB">É</div> + <div class="item">É</div> +</div> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item horizontalTB extraLeftPadding">É</div> + <div class="item extraRightPadding">É</div> + <div class="item horizontalTB">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-003-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-003-ref.html new file mode 100644 index 00000000000..03307a601de --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-003-ref.html @@ -0,0 +1,35 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 150px; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { display: inline-block; } +.top { vertical-align: top; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block verticalRL"><div class="item top horizontalTB">É</div><div class="item top horizontalTB">É</div><div class="item top horizontalTB">É</div><div class="item top horizontalTB">É</div></div> +<div class="block verticalRL"><div class="item top horizontalTB extraLeftPadding">É</div><div class="item top horizontalTB extraRightPadding">É</div><div class="item top horizontalTB">É</div><div class="item top horizontalTB">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-003.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-003.html new file mode 100644 index 00000000000..2ae2f4fba65 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-003.html @@ -0,0 +1,55 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-rl)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-rl-003-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. All the items are orthogonal to the row-axis, so they don't participate in the row-like Baseline Context; since no items shares column-like Baseline context, neither 'justify-self' or 'align-self' should apply." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 150px; + height: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with orthogonal items.</p> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item horizontalTB extraLeftPadding">É</div> + <div class="item horizontalTB extraRightPadding">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-004-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-004-ref.html new file mode 100644 index 00000000000..2e3e032ac8c --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-004-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + height: 100px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.item { display: inline-block; } +.top { vertical-align: top; } +</style> + +<p>4x1 with parallel items.</p> +<div class="block directionRTL"><div class="item top verticalRL">É</div><div class="item top verticalRL">É</div><div class="item top verticalRL">É</div><div class="item top verticalRL">É</div></div> +<div class="block directionRTL"><div class="item top verticalRL extraBottomPadding">É</div><div class="item top verticalRL">É</div><div class="item top verticalRL">É</div><div class="item top verticalRL">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-004.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-004.html new file mode 100644 index 00000000000..d2f08642fcd --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-004.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-rl)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-rl-004-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. Orthogonal items don't participate in baseline alignment in the column-like baseline; since no item shares row-like Baseline Context, neither 'aling-self' or 'justify-self' apply." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + height: 100px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraBottomPadding { padding-bottom: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>4x1 with parallel items.</p> +<div class="block grid column verticalRL contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> +<div class="block grid column verticalRL contentStart itemsBaseline"> + <div class="item extraBottomPadding">É</div> + <div class="item">É</div> + <div class="item">É</div> + <div class="item">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-005-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-005-ref.html new file mode 100644 index 00000000000..067129b8dc9 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-005-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.item { display: inline-block; } +.top { vertical-align: top; } +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block directionRTL"><div class="item top verticalRL">É</div><div class="item">É</div><div class="item top verticalRL">É</div><div class="item">É</div></div> +<div class="block directionRTL"><div class="item top verticalRL extraTopPadding">É</div><div class="item extraBottomPadding">É</div><div class="item top verticalRL">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-005.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-005.html new file mode 100644 index 00000000000..0d40ce288d7 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-005.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-rl)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-rl-005-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. Only the parallel items participate in baseline alignment in the column-like Baseline Context; since no item shares row-like Baseline Context, only 'justify-self' (row baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.column { grid-auto-flow: row } +</style> + +<p>4x1 with parallel and orthogonal items.</p> +<div class="block grid column verticalRL contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item horizontalTB">É</div> + <div class="item">É</div> + <div class="item horizontalTB">É</div> +</div> +<div class="block grid column verticalRL contentStart itemsBaseline"> + <div class="item extraTopPadding">É</div> + <div class="item horizontalTB extraBottomPadding">É</div> + <div class="item">É</div> + <div class="item horizontalTB">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-006-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-006-ref.html new file mode 100644 index 00000000000..4011c691427 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-006-ref.html @@ -0,0 +1,33 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.item { display: inline-block; } +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block directionRTL"><div class="item">É</div><div class="item">É</div><div class="item">É</div><div class="item">É</div></div> +<div class="block directionRTL"><div class="item extraBottomPadding">É</div><div class="item extraTopPadding">É</div><div class="item">É</div><div class="item">É</div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-006.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-006.html new file mode 100644 index 00000000000..40f1e0796ea --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-006.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-rl)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-rl-006-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that no item shares any row-like Baseline Context and all items share 'first-column' Baseline Context. Items participate in both, column and row baseline, but since they only share a column-like Baseline Context only 'justify-self' (row baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 350px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraTopPadding { padding-top: 30px; } +.extraBottomPadding { padding-bottom: 30px; } +.column { grid-auto-flow: row } +</style> + +<p>4x1 with orthogonal items.</p> +<div class="block grid column verticalRL contentStart itemsBaseline"> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> +<div class="block grid column verticalRL contentStart itemsBaseline"> + <div class="item horizontalTB extraBottomPadding">É</div> + <div class="item horizontalTB extraTopPadding">É</div> + <div class="item horizontalTB">É</div> + <div class="item horizontalTB">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-007-ref.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-007-ref.html new file mode 100644 index 00000000000..ffa3e0512a9 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-007-ref.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 200px; + font-family: Ahem; +} +.block1 > :nth-child(1) { font-size:24px; } +.block1 > :nth-child(2) { font-size:32px; } +.block2 > :nth-child(1) { font-size:48px; } +.block2 > :nth-child(2) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.item { display: inline-block; } +.block1, .block2 { float: left; } +</style> + +<p>1x4 with parallel items, but opposite block-flow direction.</p> +<div class="block verticalRL"><div class="block1"><div class="item">É</div><div class="item">É</div></div><div class="block2 verticalLR"><div class="item">É</div><div class="item">É</div></div></div> +<div class="block verticalRL"><div class="block1"><div class="item extraLeftPadding">É</div><div class="item extraRightPadding">É</div></div><div class="block2 verticalLR"><div class="item">É</div><div class="item">É</div></div></div></div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-007.html b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-007.html new file mode 100644 index 00000000000..49bab61ca09 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/alignment/self-baseline/grid-self-baseline-vertical-rl-007.html @@ -0,0 +1,54 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: baseline context and self alignment (vertical-rl)</title> +<link rel="author" title="Javier Fernandez" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-align-self"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-by-baseline"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-items-property"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#align-self-property"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=412410"> +<link rel="match" href="grid-self-baseline-vertical-rl-007-ref.html"> +<link rel="stylesheet" href="/fonts/ahem.css"> +<link rel="stylesheet" href="/css/support/alignment.css"> +<link rel="stylesheet" href="/css/support/grid.css"> +<meta name="assert" content="Test that all items share 'first-row' Baseline Context and no item shares any column-like Baseline Context. We have 2 baseline-sharing groups. Items participate in both, column and row baseline, but since they only share a row-like Baseline Context only 'align-self' (column baseline-axis) should apply. The Baseline Alignment may increase size contribution of some items." /> + +<style> +body { margin: 0; } +.block { + background: grey; + float: left; + margin: 5px; + text-orientation: sideways; + width: 200px; + font-family: Ahem; +} +.block > :nth-child(1) { font-size:24px; } +.block > :nth-child(2) { font-size:32px; } +.block > :nth-child(3) { font-size:48px; } +.block > :nth-child(4) { font-size:64px; } +.item { + border-width: 2px 5px 3px 4px; + border-style: solid; + padding: 6px 3px 7px 8px; + margin: 10px 6px 4px 12px; +} +.extraLeftPadding { padding-left: 30px; } +.extraRightPadding { padding-right: 30px; } +.row { grid-auto-flow: column; } +</style> + +<p>1x4 with parallel items, but opposite block-flow direction.</p> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item">É</div> + <div class="item">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> +</div> +<div class="block grid row verticalRL contentStart itemsBaseline"> + <div class="item extraLeftPadding">É</div> + <div class="item extraRightPadding">É</div> + <div class="item verticalLR">É</div> + <div class="item verticalLR">É</div> +</div> diff --git a/tests/wpt/web-platform-tests/css/css-grid/grid-items/grid-automatic-minimum-intrinsic-aspect-ratio-001.html b/tests/wpt/web-platform-tests/css/css-grid/grid-items/grid-automatic-minimum-intrinsic-aspect-ratio-001.html new file mode 100644 index 00000000000..7d472716fb7 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/grid-items/grid-automatic-minimum-intrinsic-aspect-ratio-001.html @@ -0,0 +1,107 @@ +<!DOCTYPE html> +<title>CSS Grid: automatic minimum for items with instrinsic aspect ratios</title> +<link rel="author" title="Sergio Villar" href="mailto:svillar@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#min-size-auto"> +<meta name="assert" content="Check how min-width|height:auto is computed for items with intrinsic aspect ratios."> +<link rel="stylesheet" href="/css/support/grid.css"> +<link rel="stylesheet" href="/css/support/width-keyword-classes.css"> + +<style> +.container { + border: 5px solid orange; + display: grid; +} +</style> + +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="/resources/check-layout-th.js"></script> + +<body onload="checkLayout('.container')"> +<div id="log"></div> + +<div class="container min-content" data-expected-width="60" + data-expected-height="35"> + <img src="/images/green-100x50.png" style="height: 25px;" + data-expected-width="50" data-expected-height="25"/> +</div> + +<div class="container min-content" data-expected-width="150" + data-expected-height="80"> + <img src="/images/green-100x50.png" style="min-height: 70px;" + data-expected-width="140" data-expected-height="70"/> +</div> + +<div class="container min-content" data-expected-width="90" + data-expected-height="50"> + <img src="/images/green-100x50.png" style="max-height: 40px;" + data-expected-width="80" data-expected-height="40"/> +</div> + +<div class="container min-content" data-expected-width="70" + data-expected-height="40"> + <img src="/images/green-100x50.png" style="height: 25px; min-height: 30px;" + data-expected-width="60" data-expected-height="30"/> +</div> + +<div class="container min-content" data-expected-width="30" + data-expected-height="20"> + <img src="/images/green-100x50.png" style="height: 25px; max-height: 10px;" + data-expected-width="20" data-expected-height="10"/> +</div> + +<div class="container min-content" data-expected-width="50" + data-expected-height="35"> + <img src="/images/green-100x50.png" style="height: 25px; max-width: 40px;" + data-expected-width="40" data-expected-height="25"/> +</div> + +<div class="container min-content" data-expected-width="60" + data-expected-height="40"> + <img src="/images/green-100x50.png" + style="height: 25px; min-height: 30px; max-width: 50px;" + data-expected-width="50" data-expected-height="30"/> +</div> + +<div class="container min-content" data-expected-width="60" + data-expected-height="35"> + <img src="/images/green-100x50.png" style="width: 50px;" + data-expected-width="50" data-expected-height="25"/> +</div> + +<div class="container min-content" data-expected-width="70" + data-expected-height="40"> + <img src="/images/green-100x50.png" style="max-width: 60px;" + data-expected-width="60" data-expected-height="30"/> +</div> + +<div class="container min-content" data-expected-width="130" + data-expected-height="70"> + <img src="/images/green-100x50.png" style="min-width: 120px;" + data-expected-width="120" data-expected-height="60"/> +</div> + +<div class="container min-content" data-expected-width="90" + data-expected-height="50"> + <img src="/images/green-100x50.png" style="width: 60px; min-width: 80px;" + data-expected-width="80" data-expected-height="40"/> +</div> + +<div class="container min-content" data-expected-width="34" + data-expected-height="22"> + <img src="/images/green-100x50.png" style="width: 24px; max-width: 40px;" + data-expected-width="24" data-expected-height="12"/> +</div> + +<div class="container min-content" data-expected-width="130" + data-expected-height="35"> + <img src="/images/green-100x50.png" style="width: 120px; max-height: 25px;" + data-expected-width="120" data-expected-height="25"/> +</div> + +<div class="container min-content" data-expected-width="35" + data-expected-height="110"> + <img src="/images/green-100x50.png" style="width: 25px; min-height: 100px;" + data-expected-width="25" data-expected-height="100"/> +</div> +</body> diff --git a/tests/wpt/web-platform-tests/css/css-grid/grid-model/grid-container-margin-border-padding-scrollbar-001.html b/tests/wpt/web-platform-tests/css/css-grid/grid-model/grid-container-margin-border-padding-scrollbar-001.html index 6aff5895953..8173361bbc8 100644 --- a/tests/wpt/web-platform-tests/css/css-grid/grid-model/grid-container-margin-border-padding-scrollbar-001.html +++ b/tests/wpt/web-platform-tests/css/css-grid/grid-model/grid-container-margin-border-padding-scrollbar-001.html @@ -37,7 +37,7 @@ <script src="/resources/testharnessreport.js"></script> <script src="/resources/check-layout-th.js"></script> </head> -<body onload="checkLayout('.grid');"> +<body> <div class="grid min-content" data-expected-width="100" data-expected-height="100"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> @@ -54,7 +54,7 @@ <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content scroll" data-expected-width="115" data-expected-height="115"> + <div class="grid min-content scroll" data-width-without-scrollbar="100" data-height-without-scrollbar="100"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> @@ -66,7 +66,7 @@ <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content margin scroll" data-expected-width="115" data-expected-height="115"> + <div class="grid min-content margin scroll" data-width-without-scrollbar="100" data-height-without-scrollbar="100"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> @@ -74,11 +74,11 @@ <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content border scroll" data-expected-width="125" data-expected-height="125"> + <div class="grid min-content border scroll" data-width-without-scrollbar="110" data-height-without-scrollbar="110"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content padding scroll" data-expected-width="155" data-expected-height="155"> + <div class="grid min-content padding scroll" data-width-without-scrollbar="140" data-height-without-scrollbar="140"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> @@ -86,20 +86,54 @@ <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content margin border scroll" data-expected-width="125" data-expected-height="125"> + <div class="grid min-content margin border scroll" data-width-without-scrollbar="110" data-height-without-scrollbar="110"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content margin padding scroll" data-expected-width="155" data-expected-height="155"> + <div class="grid min-content margin padding scroll" data-width-without-scrollbar="140" data-height-without-scrollbar="140"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content border padding scroll" data-expected-width="165" data-expected-height="165"> + <div class="grid min-content border padding scroll" data-width-without-scrollbar="150" data-height-without-scrollbar="150"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> - <div class="grid min-content margin border padding scroll" data-expected-width="165" data-expected-height="165"> + <div class="grid min-content margin border padding scroll" data-width-without-scrollbar="150" data-height-without-scrollbar="150"> <div class="item" data-expected-width="100" data-expected-height="100"></div> </div> + + <!-- This div is only for measuring scrollbar size --> + <div id="measure" style="overflow: scroll;"> + <div style="min-height: 300px;"></div> + </div> + +<script> + var measure = document.getElementById('measure'); + var scrollbarWidth = measure.offsetWidth - measure.clientWidth; + var scrollbarHeight = measure.offsetHeight - measure.clientHeight; + + // Here are the data-width-without-scrollbar (and height) attributes of all + // elements that have the "scroll" class. Things that contribute to the expected + // sizes are: + // + // - width: + // padding{Left,Right}, border{Left,Right}, element width and its scrollbarWidth. + // + // - height: + // padding{Top,Bottom}, border{Top, Bottom}, element width and its scrollbarHeight. + // + // The data-expected-width (and height) attributes are dynamically set to the elements + // so that we can ensure the scrollbar sizes are calculated in an engine-agnostic way. + var elements = document.getElementsByClassName("scroll"); + for (var i = 0; i < elements.length; i++) { + const expectedWidth = parseInt(elements[i].getAttribute("data-width-without-scrollbar")); + const expectedHeight = parseInt(elements[i].getAttribute("data-height-without-scrollbar")); + elements[i].setAttribute("data-expected-width", expectedWidth + scrollbarWidth); + elements[i].setAttribute("data-expected-height", expectedHeight + scrollbarHeight); + } + + checkLayout('.grid'); +</script> + </body> </html> diff --git a/tests/wpt/web-platform-tests/css/css-grid/grid-model/grid-container-scrollbars-sizing-002.html b/tests/wpt/web-platform-tests/css/css-grid/grid-model/grid-container-scrollbars-sizing-002.html new file mode 100644 index 00000000000..99cc5ee771d --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/grid-model/grid-container-scrollbars-sizing-002.html @@ -0,0 +1,34 @@ +<!DOCTYPE html> +<title>CSS Grid Layout Test: Intrinsic logical width with scrollbars</title> +<link rel="author" title="Sunil Ratnu" href="mailto:sunil.ratnu@samsung.com"> +<link rel="issue" href="https://codereview.chromium.org/535913002"/> +<link rel="help" href="https://drafts.csswg.org/css-grid/#overflow"/> +<link rel="stylesheet" href="/css/support/grid.css"> +<link rel="stylesheet" href="/css/support/width-keyword-classes.css"> +<link rel="match" href="../reference/grid-container-scrollbars-sizing-002-ref.html"> +<meta name="assert" content="This test ensures that the grid container considers the scrollbars when computing the intrinsic logical widths."/> + +<style> +.grid, .inline-grid { + overflow: scroll; +} +.gridItem { + width: 100px; + height: 100px; + background: green; +} +</style> +<body> +<div class='grid fit-content'> + <span class='gridItem'></span> +</div> +<div class='grid fit-content' style='overflow-y: hidden'> + <span class='gridItem'></span> +</div> +<div class='inline-grid fit-content'> + <span class='gridItem'></span> +</div> +<div class='inline-grid fit-content' style='overflow-y: hidden'> + <span class='gridItem'></span> +</div> +</body> diff --git a/tests/wpt/web-platform-tests/css/css-grid/layout-algorithm/grid-automatic-minimum-for-auto-rows-001.html b/tests/wpt/web-platform-tests/css/css-grid/layout-algorithm/grid-automatic-minimum-for-auto-rows-001.html new file mode 100644 index 00000000000..77e9c22294d --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/layout-algorithm/grid-automatic-minimum-for-auto-rows-001.html @@ -0,0 +1,278 @@ +<!DOCTYPE html> +<title>CSS Grid: automatic minimum in 'auto' rows</title> +<link rel="author" title="Sergio Villar" href="mailto:svillar@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid/#layout-algorithm"> +<link rel="help" href="https://drafts.csswg.org/css-sizing-3/#automatic-minimum-size"> +<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=464287"> +<meta name="assert" content="Check that grid item's 'min-width' is honored when sizing 'auto' rows."> +<link rel="stylesheet" href="/css/support/grid.css"> +<link rel="stylesheet" href="/fonts/ahem.css"> + +<style> +.grid { font: 10px/1 Ahem; } + +.minHeight10 { min-height: 10px; } +.minHeight20 { min-height: 20px; } +.minHeight30 { min-height: 30px; } +.minHeight40 { min-height: 40px; } +.minHeight50 { min-height: 50px; } +.minHeight60 { min-height: 60px; } +.minHeight70 { min-height: 70px; } +.minHeight90 { min-height: 90px; } +.minHeightMaxContent { min-height: max-content; } + +.height30 { height: 30px; } +.height50 { height: 50px; } +.height60 { height: 60px; } +.height200 { height: 200px; } + +.border5 { border: 5px solid #abc; } +.padding8 { padding: 8px 0px; } + +/* All these 4 cases are equivalent. We use them interchangeably. */ +.gridAuto { grid-template-rows: auto; } +.gridMinMaxAutoAuto { grid-template-rows: minmax(auto, auto); } +.gridMinMaxAutoMaxContent { grid-template-rows: minmax(auto, max-content); } +.gridMinMaxMinContentAuto { grid-template-rows: minmax(min-content, auto); } + +/* All these 3 cases are equivalent. We use them interchangeably. */ +.gridAutoAndAuto { grid-template-rows: auto auto; } +.gridAutoAndMinMaxAutoAuto { grid-template-rows: auto minmax(auto, auto); } +.gridMinMaxAutoMaxContentAndAuto { grid-template-rows: minmax(auto, max-content) auto; } + +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> + +<div class="grid gridAuto constrainedContainer" id="gridAuto"> + <div class="firstRowFirstColumn minHeight40">XX<br>XXX<br>XX<br>XXX<br>XXXX</div> +</div> + +<div class="grid gridAuto constrainedContainer" id="gridAutoItemSmallerThanMinSize"> + <div class="firstRowFirstColumn minHeight40">XX</div> +</div> + +<div class="grid gridMinMaxAutoAuto constrainedContainer" id="gridMinMaxAutoAuto"> + <div class="firstRowFirstColumn minHeight40">XX<br>XX</div> +</div> + +<div class="grid gridMinMaxAutoMaxContent constrainedContainer" id="gridMinMaxAutoMaxContent"> + <div class="firstRowFirstColumn minHeight20 height30"></div> +</div> + +<div class="grid gridMinMaxMinContentAuto constrainedContainer" id="gridMinMaxMinContentAuto"> + <div class="firstRowFirstColumn minHeight60">X</div> +</div> + +<div class="grid gridAuto constrainedContainer" id="gridAutoMultipleItems"> + <div class="firstRowFirstColumn minHeight60">X<br>X</div> + <div class="firstRowSecondColumn minHeight20"">XXX<br>X<br>XX<br>XX</div> + <div class="firstRowAutoColumn minConstrainedContainer height50"></div> +</div> + +<div class="grid gridMinMaxAutoAuto constrainedContainer" id="gridMinMaxAutoAutoMultipleItemsOneWithoutMinHeight"> + <div class="firstRowFirstColumn height30">X<br>X</div> + <div class="firstRowSecondColumn minHeight50"></div> + <div class="firstRowAutoColumn minHeight20">XXXX<br>X<br>XX<br>XXX</div> +</div> + +<div class="grid gridMinMaxAutoMaxContent constrainedContainer" id="gridMinMaxAutoMaxContentMultipleItemsOneWithAutoMinHeight"> + <div class="firstRowFirstColumn minHeight30">X<br>X</div> + <div class="firstRowSecondColumn height60">XX</div> + <div class="firstRowAutoColumn minHeight20">XXX<br>XX<br>XXX<br>XX</div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndAuto" id="gridAutoAndAutoFixedHeightChildren"> + <div class="firstRowFirstColumn height200"></div> + <div class="secondRowFirstColumn height50"></div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndAuto" id="gridAutoAndAutoOneSpanningOneNonSpannig"> + <div class="firstRowFirstColumn">XX XX</div> + <div class="bothRowFirstColumn minHeight50">XXXXXX X XXX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndAuto" id="gridAutoAndAutoOneSpanningMultipleNonSpanning"> + <div class="bothRowSecondColumn minHeight60">XX XX XX</div> + <div class="firstRowFirstColumn">X X X X</div> + <div class="firstRowFirstColumn">XX XX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndMinMaxAutoAuto" id="gridAutoAndMinMaxAutoAutoOneSpanningOneNonSpanning"> + <div class="secondRowFirstColumn">X XXX XX</div> + <div class="bothRowSecondColumn minHeight70">XXX XXXX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndMinMaxAutoAuto" id="gridAutoAndMinMaxAutoAutoMultipleSpanning"> + <div class="bothRowSecondColumn minHeight70">XX XX XX</div> + <div class="bothRowFirstColumn">XXXXX X XXXXX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridMinMaxAutoMaxContentAndAuto" + id="gridMinMaxAutoMaxContentAndAutoOneSpanningMultipleNonSpanning"> + <div class="secondRowFirstColumn minHeight60">X XXX XX</div> + <div class="bothRowSecondColumn minHeight90">XXXXX XXXXX</div> + <div class="firstRowFirstColumn">XX XX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridMinMaxAutoMaxContentAndAuto" + id="gridMinMaxAutoMaxContentAndAutoMultipleSpanningMultipleNonSpanning"> + <div class="bothRowSecondColumn">XX XX XX XX</div> + <div class="firstRowFirstColumn minHeight40">XXX</div> + <div class="bothRowFirstColumn minHeight90">X XX XXX</div> + <div class="secondRowFirstColumn">X XX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoWithFixedHeightChild"> + <div class="firstRowFirstColumn height60">XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto height30" id="gridAutoWithFixedHeightChildAndMinHeight"> + <div class="firstRowFirstColumn height60 minHeight40">XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoWithFixedHeightChildAndHigherMinHeight"> + <div class="firstRowFirstColumn height60 minHeight90">XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndAuto" id="gridAutoAndAutoOneSpanningFixedHeight"> + <div class="bothRowFirstColumn height50">XX XXX XX XXX XX XXX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndAuto height30" id="gridAutoAndAutoOneSpanningFixedHeightAndMinHeight"> + <div class="bothRowFirstColumn height60 minHeight50">XX XXX XX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAutoAndAuto" id="gridAutoAndAutoOneSpanningFixedHeightAndHigherMinHeight"> + <div class="bothRowFirstColumn height60 minHeight70">XX XXX XX X XX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoFixedMinHeightWithBorder"> + <div class="firstRowFirstColumn minHeight40 border5">XXXXXX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoFixedMinHeightWithPadding"> + <div class="firstRowFirstColumn minHeight40 padding8">XXXXXX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoFixedMinHeightWithBorderAndPadding"> + <div class="firstRowFirstColumn minHeight40 border5 padding8">XXXXXX</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoAutoMinHeightWithBorder"> + <div class="firstRowFirstColumn border5">XX<br>XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoAutoMinHeightWithPadding"> + <div class="firstRowFirstColumn padding8">XX<br>XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoAutoMinHeightWithBorderAndPadding"> + <div class="firstRowFirstColumn border5 padding8">XX<br>XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoMaxContentMinHeightWithBorder"> + <div class="firstRowFirstColumn minHeightMaxContent border5">XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoMaxContentMinHeightWithPadding"> + <div class="firstRowFirstColumn minHeightMaxContent padding8">XXX X</div> + </div> +</div> + +<div class="constrainedContainer"> + <div class="grid gridAuto" id="gridAutoMaxContentMinHeightWithBorderAndPadding"> + <div class="firstRowFirstColumn border5 padding8 minHeightMaxContent">XXX X</div> + </div> +</div> + +<script> +function testGridRowsValues(id, computedRowValue) +{ + assert_equals(window.getComputedStyle(document.getElementById(id)) + .getPropertyValue('grid-template-rows')", computedRowValue); +} + +setup({ explicit_done: true }); +document.fonts.ready.then(() => { + test(() => { + testGridRowsValues('gridAuto', '40px'); + testGridRowsValues('gridAutoItemSmallerThanMinSize', '40px'); + testGridRowsValues('gridMinMaxAutoAuto', '40px'); + testGridRowsValues('gridMinMaxAutoMaxContent', '30px'); + testGridRowsValues('gridMinMaxMinContentAuto', '60px'); + testGridRowsValues('gridAutoMultipleItems', '60px'); + testGridRowsValues('gridMinMaxAutoAutoMultipleItemsOneWithoutMinHeight', '50px'); + testGridRowsValues('gridMinMaxAutoMaxContentMultipleItemsOneWithAutoMinHeight', '60px'); + testGridRowsValues('gridAutoAndAutoFixedHeightChildren', '200px 50px'); + }, 'Check that min-height is honored when sizing auto rows.'); + test(() => { + testGridRowsValues('gridAutoAndAutoOneSpanningOneNonSpannig', '10px 40px'); + testGridRowsValues('gridAutoAndAutoOneSpanningMultipleNonSpanning', '40px 20px'); + testGridRowsValues('gridAutoAndMinMaxAutoAutoOneSpanningOneNonSpanning', '40px 30px'); + testGridRowsValues('gridAutoAndMinMaxAutoAutoMultipleSpanning', '35px 35px'); + testGridRowsValues('gridMinMaxAutoMaxContentAndAutoOneSpanningMultipleNonSpanning', '25px 65px'); + testGridRowsValues('gridMinMaxAutoMaxContentAndAutoMultipleSpanningMultipleNonSpanning', '50px 40px'); + }, 'Check that min-height is honored when sizing auto rows and spanning grid items.'); + test(() => { + testGridRowsValues('gridAutoWithFixedHeightChild', '60px'); + testGridRowsValues('gridAutoWithFixedHeightChildAndMinHeight', '60px'); + testGridRowsValues('gridAutoWithFixedHeightChildAndHigherMinHeight', '90px'); + testGridRowsValues('gridAutoAndAutoOneSpanningFixedHeight', '25px 25px'); + testGridRowsValues('gridAutoAndAutoOneSpanningFixedHeightAndMinHeight', '30px 30px'); + testGridRowsValues('gridAutoAndAutoOneSpanningFixedHeightAndHigherMinHeight', '35px 35px'); + }, 'Check the interactions between height and min-height and auto tracks.'); + test(() => { + testGridRowsValues('gridAutoFixedMinHeightWithBorder', '50px'); + testGridRowsValues('gridAutoFixedMinHeightWithPadding', '56px'); + testGridRowsValues('gridAutoFixedMinHeightWithBorderAndPadding', '66px'); + testGridRowsValues('gridAutoAutoMinHeightWithBorder', '40px'); + testGridRowsValues('gridAutoAutoMinHeightWithPadding', '46px'); + testGridRowsValues('gridAutoAutoMinHeightWithBorderAndPadding', '56px'); + testGridRowsValues('gridAutoMaxContentMinHeightWithBorder', '30px'); + testGridRowsValues('gridAutoMaxContentMinHeightWithPadding', '36px'); + testGridRowsValues('gridAutoMaxContentMinHeightWithBorderAndPadding', '46px'); + }, 'Check that borders and paddings are considering when computing min sizes.'); + done(); +}); +</script> diff --git a/tests/wpt/web-platform-tests/css/css-grid/reference/grid-container-scrollbars-sizing-002-ref.html b/tests/wpt/web-platform-tests/css/css-grid/reference/grid-container-scrollbars-sizing-002-ref.html new file mode 100644 index 00000000000..d77d7f8066a --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-grid/reference/grid-container-scrollbars-sizing-002-ref.html @@ -0,0 +1,37 @@ +<!DOCTYPE html> +<style> +.grid { + display: block; + background-color: grey; + overflow: scroll; +} +.inline-grid { + display: inline-block; + background-color: grey; + overflow: scroll; +} +.gridItem { + display: block; + width: 100px; + height: 100px; + background: green; +} +.fit-content { + width: -moz-fit-content; + width: fit-content; +} +</style> +<body> +<div class='grid fit-content'> + <span class='gridItem'></span> +</div> +<div class='grid fit-content' style='overflow-y: hidden'> + <span class='gridItem'></span> +</div> +<div class='inline-grid fit-content'> + <span class='gridItem'></span> +</div> +<div class='inline-grid fit-content' style='overflow-y: hidden'> + <span class='gridItem'></span> +</div> +</body> diff --git a/tests/wpt/web-platform-tests/css/css-logical/getComputedStyle-listing.html b/tests/wpt/web-platform-tests/css/css-logical/getComputedStyle-listing.html new file mode 100644 index 00000000000..5970bcea631 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-logical/getComputedStyle-listing.html @@ -0,0 +1,106 @@ +<!DOCTYPE html> +<meta charset="utf-8" /> +<title>CSS Logical Properties: computed style listing</title> +<link rel="author" title="Oriol Brufau" href="mailto:obrufau@igalia.com" /> +<link rel="help" href="https://drafts.csswg.org/css-logical/#margin-properties"> +<meta name="assert" content="This test checks that the logical properties are properly exposed in a computed CSSStyleDeclaration." /> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> + +<div id="log"></div> + +<script> +function hasProperty(object, property) { + // This checks the [[HasProperty]] internal method. + return property in object; +} + +function hasPropertyValue(object, property) { + // This checks the [[Get]] internal method. + return object[property] !== undefined; +} + +function hasPropertyDescriptor(object, property) { + // This checks [[GetOwnProperty]], iterating the prototype chain. + while (object) { + if (Reflect.getOwnPropertyDescriptor(object, property)) { + return true; + } + object = Reflect.getPrototypeOf(object); + } + return false; +} + +function hasPropertyKey(object, property) { + // This checks [[OwnPropertyKeys]], iterating the prototype chain. + while (object) { + if (Reflect.ownKeys(object).includes(property)) { + return true; + } + object = Reflect.getPrototypeOf(object); + } + return false; +} + +function hasItem(object, item) { + // This checks the CSSStyleDeclaration::item WebIDL getter. + for (let i = 0; i < object.length; ++i) { + if (object.item(i) === item) { + return true; + } + } + return false; +} + +function check(property) { + const cs = getComputedStyle(document.body); + const camelCase = property.replace(/-(.)/g, (_, b) => b.toUpperCase()); + test(function() { + assert_true(hasProperty(cs, property) || hasProperty(cs, camelCase), + `The computed style has the property ${property} or ${camelCase}.`); + assert_true(hasPropertyValue(cs, property) || hasPropertyValue(cs, camelCase), + `The computed style has a value for for the property ${property} or ${camelCase}.`); + assert_true(hasPropertyDescriptor(cs, property) || hasPropertyDescriptor(cs, camelCase), + `The computed style has a property descriptor for ${property} or ${camelCase}.`); + assert_true(hasPropertyKey(cs, property) || hasPropertyKey(cs, camelCase), + `The computed style contains ${property} or ${camelCase} in the property list.`); + assert_true(hasItem(cs, property) || hasItem(cs, camelCase), + `The computed style contains the item ${property} or ${camelCase}.`); + }, property); +} + +check("border-block-end-color"); +check("border-block-end-style"); +check("border-block-end-width"); +check("border-block-start-color"); +check("border-block-start-style"); +check("border-block-start-width"); +check("border-inline-end-color"); +check("border-inline-end-style"); +check("border-inline-end-width"); +check("border-inline-start-color"); +check("border-inline-start-style"); +check("border-inline-start-width"); + +check("inset-block-start"); +check("inset-block-end"); +check("inset-inline-start"); +check("inset-inline-end"); + +check("margin-block-start"); +check("margin-block-end"); +check("margin-inline-start"); +check("margin-inline-end"); + +check("padding-block-start"); +check("padding-block-end"); +check("padding-inline-start"); +check("padding-inline-end"); + +check("block-size"); +check("inline-size"); +check("max-block-size"); +check("max-inline-size"); +check("min-block-size"); +check("min-inline-size"); +</script> diff --git a/tests/wpt/web-platform-tests/css/css-text/white-space/reference/trailing-space-rtl-001-ref.html b/tests/wpt/web-platform-tests/css/css-text/white-space/reference/trailing-space-rtl-001-ref.html new file mode 100644 index 00000000000..f3f25235911 --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-text/white-space/reference/trailing-space-rtl-001-ref.html @@ -0,0 +1,19 @@ +<!DOCTYPE html> +<style> +body { + direction: rtl; + white-space: pre-wrap; +} +.bg { + background: orange; +} +.override { + unicode-bidi: bidi-override; +} +</style> +<body> +<div>אבג <span class="bg">אבגד</span> אבגדה</div> +<div>אבג <span class="bg">אבגד</span> אבגדה</div> +<div class="override">123 <span class="bg override">12345</span> 1234567</div> +<div class="override">123 <span class="bg override">12345</span> 1234567</div> +</body> diff --git a/tests/wpt/web-platform-tests/css/css-text/white-space/trailing-space-rtl-001.html b/tests/wpt/web-platform-tests/css/css-text/white-space/trailing-space-rtl-001.html new file mode 100644 index 00000000000..8bc6cc75cbe --- /dev/null +++ b/tests/wpt/web-platform-tests/css/css-text/white-space/trailing-space-rtl-001.html @@ -0,0 +1,23 @@ +<!DOCTYPE html> +<title>CSS Test: Preserved trailing spaces in RTL</title> +<link rel="match" href="reference/trailing-space-rtl-001-ref.html"> +<link rel="help" href="https://drafts.csswg.org/css-text-3/#white-space-phase-2"> +<link rel="author" title="Koji Ishii" href="mailto:kojii@chromium.org"> +<style> +body { + direction: rtl; + white-space: pre-wrap; +} +.bg { + background: orange; +} +.override { + unicode-bidi: bidi-override; +} +</style> +<body> +<div>אבג <span class="bg">אבגד</span> אבגדה</div> +<div>אבג <span class="bg">אבגד</span> אבגדה </div> +<div class="override">123 <span class="bg override">12345</span> 1234567</div> +<div class="override">123 <span class="bg override">12345</span> 1234567 </div> +</body> diff --git a/tests/wpt/web-platform-tests/custom-elements/customized-built-in-constructor-exceptions.html b/tests/wpt/web-platform-tests/custom-elements/customized-built-in-constructor-exceptions.html new file mode 100644 index 00000000000..32729bdb6bb --- /dev/null +++ b/tests/wpt/web-platform-tests/custom-elements/customized-built-in-constructor-exceptions.html @@ -0,0 +1,75 @@ +<!DOCTYPE html> +<title>Customized built-in element constructor behavior</title> +<meta name='author' title='Mason Freed' href='mailto:masonfreed@chromium.org'> +<link rel='help' href='https://dom.spec.whatwg.org/#concept-create-element'> +<script src='/resources/testharness.js'></script> +<script src='/resources/testharnessreport.js'></script> + +<script> +setup({allow_uncaught_exception : true}); + +class MyCustomParagraph extends HTMLParagraphElement { + constructor() { + super(); + this.textContent = 'PASS'; + } +} +customElements.define('custom-p', MyCustomParagraph, { extends: 'p' }); +</script> +<p id=targetp is='custom-p'></p> +<script> +test(t => { + let target = document.getElementById('targetp'); + assert_true(!!target); + assert_equals(target.localName, 'p'); + assert_true(target instanceof MyCustomParagraph); + assert_true(target instanceof HTMLParagraphElement); + assert_equals(target.childNodes.length, 1); + assert_equals(target.textContent, 'PASS'); +}, 'Appending children in customized built-in constructor should work'); +</script> + + +<script> +class MyCustomVideo extends HTMLVideoElement { + constructor() { + super(); + throw new Error(); + } +} +customElements.define('custom-video', MyCustomVideo, { extends: 'video' }); +</script> +<video id=targetvideo is='custom-video'> <source></source> </video> +<script> +test(t => { + let target = document.getElementById('targetvideo'); + assert_true(!!target); + assert_equals(target.localName, 'video'); + assert_true(target instanceof MyCustomVideo); + assert_true(target instanceof HTMLVideoElement); + assert_equals(target.children.length, 1); +}, 'Throwing exception in customized built-in constructor should not crash and should return correct element type (video)'); +</script> + + +<script> +class MyCustomForm extends HTMLFormElement { + constructor() { + super(); + throw new Error(); + } +} +customElements.define('custom-form', MyCustomForm, { extends: 'form' }); +</script> +<form id=targetform is='custom-form'> <label></label><input> </form> +<script> +test(t => { + let target = document.getElementById('targetform'); + assert_true(!!target); + assert_equals(target.localName, 'form'); + assert_true(target instanceof MyCustomForm); + assert_true(target instanceof HTMLFormElement); + assert_equals(target.children.length, 2); +}, 'Throwing exception in customized built-in constructor should not crash and should return correct element type (form)'); +</script> + diff --git a/tests/wpt/web-platform-tests/device-memory/device-memory.https.any.js b/tests/wpt/web-platform-tests/device-memory/device-memory.https.any.js index 8f81ffc31f4..4fe6f04ebc9 100644 --- a/tests/wpt/web-platform-tests/device-memory/device-memory.https.any.js +++ b/tests/wpt/web-platform-tests/device-memory/device-memory.https.any.js @@ -5,4 +5,4 @@ test(function() { "navigator.deviceMemory returns a positive value"); assert_true([0.25, 0.5, 1, 2, 4, 8].includes(navigator.deviceMemory), "navigator.deviceMemory returns a power of 2 between 0.25 and 8"); -}, "navigator.deviceMemory is a positive number, a power of 2, between 0.25 and 8");
\ No newline at end of file +}, "navigator.deviceMemory is a positive number, a power of 2, between 0.25 and 8"); diff --git a/tests/wpt/web-platform-tests/dom/nodes/Node-insertBefore.html b/tests/wpt/web-platform-tests/dom/nodes/Node-insertBefore.html index 6977501501d..ce8b3d8a57b 100644 --- a/tests/wpt/web-platform-tests/dom/nodes/Node-insertBefore.html +++ b/tests/wpt/web-platform-tests/dom/nodes/Node-insertBefore.html @@ -8,8 +8,11 @@ <script> var insertFunc = Node.prototype.insertBefore; </script> -<script src="pre-insertion-checks.js"></script> +<script src="pre-insertion-validation-notfound.js"></script> +<script src="pre-insertion-validation-hierarchy.js"></script> <script> +preInsertionValidateHierarchy("insertBefore"); + function testLeafNode(nodeName, createNodeFunction) { test(function() { var node = createNodeFunction(); @@ -75,30 +78,6 @@ test(function() { df.appendChild(doc.createElement("a")); df.appendChild(doc.createElement("b")); assert_throws_dom("HierarchyRequestError", function() { - doc.insertBefore(df, null); - }); - - df = doc.createDocumentFragment(); - df.appendChild(doc.createTextNode("text")); - assert_throws_dom("HierarchyRequestError", function() { - doc.insertBefore(df, null); - }); - - df = doc.createDocumentFragment(); - df.appendChild(doc.createComment("comment")); - df.appendChild(doc.createTextNode("text")); - assert_throws_dom("HierarchyRequestError", function() { - doc.insertBefore(df, null); - }); -}, "If the context node is a document, appending a DocumentFragment that contains a text node or too many elements should throw a HierarchyRequestError.") -test(function() { - var doc = document.implementation.createHTMLDocument("title"); - doc.removeChild(doc.documentElement); - - var df = doc.createDocumentFragment(); - df.appendChild(doc.createElement("a")); - df.appendChild(doc.createElement("b")); - assert_throws_dom("HierarchyRequestError", function() { doc.insertBefore(df, doc.firstChild); }); diff --git a/tests/wpt/web-platform-tests/dom/nodes/Node-replaceChild.html b/tests/wpt/web-platform-tests/dom/nodes/Node-replaceChild.html index e942cfa3ec4..74aac67d432 100644 --- a/tests/wpt/web-platform-tests/dom/nodes/Node-replaceChild.html +++ b/tests/wpt/web-platform-tests/dom/nodes/Node-replaceChild.html @@ -10,7 +10,7 @@ <script> var insertFunc = Node.prototype.replaceChild; </script> -<script src="pre-insertion-checks.js"></script> +<script src="pre-insertion-validation-notfound.js"></script> <script> // IDL. test(function() { diff --git a/tests/wpt/web-platform-tests/dom/nodes/ParentNode-append.html b/tests/wpt/web-platform-tests/dom/nodes/ParentNode-append.html index dcc398f3f58..4e101f73a25 100644 --- a/tests/wpt/web-platform-tests/dom/nodes/ParentNode-append.html +++ b/tests/wpt/web-platform-tests/dom/nodes/ParentNode-append.html @@ -4,44 +4,45 @@ <link rel=help href="https://dom.spec.whatwg.org/#dom-parentnode-append"> <script src="/resources/testharness.js"></script> <script src="/resources/testharnessreport.js"></script> +<script src="pre-insertion-validation-hierarchy.js"></script> <script> +preInsertionValidateHierarchy("append"); function test_append(node, nodeName) { - test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.append(); assert_array_equals(parent.childNodes, []); }, nodeName + '.append() without any argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.append(null); assert_equals(parent.childNodes[0].textContent, 'null'); }, nodeName + '.append() with null as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.append(undefined); assert_equals(parent.childNodes[0].textContent, 'undefined'); }, nodeName + '.append() with undefined as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.append('text'); assert_equals(parent.childNodes[0].textContent, 'text'); }, nodeName + '.append() with only text as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); - var x = document.createElement('x'); + const parent = node.cloneNode(); + const x = document.createElement('x'); parent.append(x); assert_array_equals(parent.childNodes, [x]); }, nodeName + '.append() with only one element as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); - var child = document.createElement('test'); + const parent = node.cloneNode(); + const child = document.createElement('test'); parent.appendChild(child); parent.append(null); assert_equals(parent.childNodes[0], child); @@ -49,9 +50,9 @@ function test_append(node, nodeName) { }, nodeName + '.append() with null as an argument, on a parent having a child.'); test(function() { - var parent = node.cloneNode(); - var x = document.createElement('x'); - var child = document.createElement('test'); + const parent = node.cloneNode(); + const x = document.createElement('x'); + const child = document.createElement('test'); parent.appendChild(child); parent.append(x, 'text'); assert_equals(parent.childNodes[0], child); @@ -61,6 +62,6 @@ function test_append(node, nodeName) { } test_append(document.createElement('div'), 'Element'); -test_append(document.createDocumentFragment(), 'DocumentFrgment'); +test_append(document.createDocumentFragment(), 'DocumentFragment'); </script> </html> diff --git a/tests/wpt/web-platform-tests/dom/nodes/ParentNode-prepend.html b/tests/wpt/web-platform-tests/dom/nodes/ParentNode-prepend.html index 644693ffe6d..f6aa38a2dd5 100644 --- a/tests/wpt/web-platform-tests/dom/nodes/ParentNode-prepend.html +++ b/tests/wpt/web-platform-tests/dom/nodes/ParentNode-prepend.html @@ -4,44 +4,45 @@ <link rel=help href="https://dom.spec.whatwg.org/#dom-parentnode-prepend"> <script src="/resources/testharness.js"></script> <script src="/resources/testharnessreport.js"></script> +<script src="pre-insertion-validation-hierarchy.js"></script> <script> +preInsertionValidateHierarchy("prepend"); function test_prepend(node, nodeName) { - test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.prepend(); assert_array_equals(parent.childNodes, []); }, nodeName + '.prepend() without any argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.prepend(null); assert_equals(parent.childNodes[0].textContent, 'null'); }, nodeName + '.prepend() with null as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.prepend(undefined); assert_equals(parent.childNodes[0].textContent, 'undefined'); }, nodeName + '.prepend() with undefined as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); + const parent = node.cloneNode(); parent.prepend('text'); assert_equals(parent.childNodes[0].textContent, 'text'); }, nodeName + '.prepend() with only text as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); - var x = document.createElement('x'); + const parent = node.cloneNode(); + const x = document.createElement('x'); parent.prepend(x); assert_array_equals(parent.childNodes, [x]); }, nodeName + '.prepend() with only one element as an argument, on a parent having no child.'); test(function() { - var parent = node.cloneNode(); - var child = document.createElement('test'); + const parent = node.cloneNode(); + const child = document.createElement('test'); parent.appendChild(child); parent.prepend(null); assert_equals(parent.childNodes[0].textContent, 'null'); @@ -49,9 +50,9 @@ function test_prepend(node, nodeName) { }, nodeName + '.prepend() with null as an argument, on a parent having a child.'); test(function() { - var parent = node.cloneNode(); - var x = document.createElement('x'); - var child = document.createElement('test'); + const parent = node.cloneNode(); + const x = document.createElement('x'); + const child = document.createElement('test'); parent.appendChild(child); parent.prepend(x, 'text'); assert_equals(parent.childNodes[0], x); @@ -61,6 +62,6 @@ function test_prepend(node, nodeName) { } test_prepend(document.createElement('div'), 'Element'); -test_prepend(document.createDocumentFragment(), 'DocumentFrgment'); +test_prepend(document.createDocumentFragment(), 'DocumentFragment'); </script> </html> diff --git a/tests/wpt/web-platform-tests/dom/nodes/ParentNode-replaceChildren.html b/tests/wpt/web-platform-tests/dom/nodes/ParentNode-replaceChildren.html new file mode 100644 index 00000000000..6557db44128 --- /dev/null +++ b/tests/wpt/web-platform-tests/dom/nodes/ParentNode-replaceChildren.html @@ -0,0 +1,118 @@ +<!DOCTYPE html> +<meta charset=utf-8> +<title>ParentNode.replaceChildren</title> +<link rel=help href="https://dom.spec.whatwg.org/#dom-parentnode-replacechildren"> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="pre-insertion-validation-hierarchy.js"></script> +<script> + preInsertionValidateHierarchy("replaceChildren"); + + function test_replacechildren(node, nodeName) { + test(() => { + const parent = node.cloneNode(); + parent.replaceChildren(); + assert_array_equals(parent.childNodes, []); + }, `${nodeName}.replaceChildren() without any argument, on a parent having no child.`); + + test(() => { + const parent = node.cloneNode(); + parent.replaceChildren(null); + assert_equals(parent.childNodes[0].textContent, 'null'); + }, `${nodeName}.replaceChildren() with null as an argument, on a parent having no child.`); + + test(() => { + const parent = node.cloneNode(); + parent.replaceChildren(undefined); + assert_equals(parent.childNodes[0].textContent, 'undefined'); + }, `${nodeName}.replaceChildren() with undefined as an argument, on a parent having no child.`); + + test(() => { + const parent = node.cloneNode(); + parent.replaceChildren('text'); + assert_equals(parent.childNodes[0].textContent, 'text'); + }, `${nodeName}.replaceChildren() with only text as an argument, on a parent having no child.`); + + test(() => { + const parent = node.cloneNode(); + const x = document.createElement('x'); + parent.replaceChildren(x); + assert_array_equals(parent.childNodes, [x]); + }, `${nodeName}.replaceChildren() with only one element as an argument, on a parent having no child.`); + + test(() => { + const parent = node.cloneNode(); + const child = document.createElement('test'); + parent.appendChild(child); + parent.replaceChildren(null); + assert_equals(parent.childNodes.length, 1); + assert_equals(parent.childNodes[0].textContent, 'null'); + }, `${nodeName}.replaceChildren() with null as an argument, on a parent having a child.`); + + test(() => { + const parent = node.cloneNode(); + const x = document.createElement('x'); + const child = document.createElement('test'); + parent.appendChild(child); + parent.replaceChildren(x, 'text'); + assert_equals(parent.childNodes.length, 2); + assert_equals(parent.childNodes[0], x); + assert_equals(parent.childNodes[1].textContent, 'text'); + }, `${nodeName}.replaceChildren() with one element and text as argument, on a parent having a child.`); + + async_test(t => { + let phase = 0; + + const previousParent = node.cloneNode(); + const insertions = [ + document.createElement("test1"), + document.createElement("test2") + ]; + previousParent.append(...insertions); + + const parent = node.cloneNode(); + const children = [ + document.createElement("test3"), + document.createElement("test4") + ]; + parent.append(...children); + + const previousObserver = new MutationObserver(mutations => { + t.step(() => { + assert_equals(phase, 0); + assert_equals(mutations.length, 2); + for (const [i, mutation] of Object.entries(mutations)) { + assert_equals(mutation.type, "childList"); + assert_equals(mutation.addedNodes.length, 0); + assert_equals(mutation.removedNodes.length, 1); + assert_equals(mutation.removedNodes[0], insertions[i]); + } + phase = 1; + }); + }); + previousObserver.observe(previousParent, { childList: true }); + + const observer = new MutationObserver(mutations => { + t.step(() => { + assert_equals(phase, 1); + assert_equals(mutations.length, 1); + const mutation = mutations[0]; + assert_equals(mutation.type, "childList"); + assert_equals(mutation.addedNodes.length, 2); + assert_array_equals([...mutation.addedNodes], insertions); + assert_equals(mutation.removedNodes.length, 2); + assert_array_equals([...mutation.removedNodes], children); + }); + t.done(); + }); + observer.observe(parent, { childList: true }); + + parent.replaceChildren(...previousParent.children); + }, `${nodeName}.replaceChildren() should move nodes in the right order`); + } + + test_replacechildren(document.createElement('div'), 'Element'); + test_replacechildren(document.createDocumentFragment(), 'DocumentFragment'); +</script> + +</html> diff --git a/tests/wpt/web-platform-tests/dom/nodes/pre-insertion-validation-hierarchy.js b/tests/wpt/web-platform-tests/dom/nodes/pre-insertion-validation-hierarchy.js new file mode 100644 index 00000000000..6ef2576df2c --- /dev/null +++ b/tests/wpt/web-platform-tests/dom/nodes/pre-insertion-validation-hierarchy.js @@ -0,0 +1,86 @@ +/** + * Validations where `child` argument is irrelevant. + * @param {Function} methodName + */ +function preInsertionValidateHierarchy(methodName) { + function insert(parent, node) { + if (parent[methodName].length > 1) { + // This is for insertBefore(). We can't blindly pass `null` for all methods + // as doing so will move nodes before validation. + parent[methodName](node, null); + } else { + parent[methodName](node); + } + } + + // Step 2 + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + assert_throws_dom("HierarchyRequestError", () => insert(doc.body, doc.body)); + assert_throws_dom("HierarchyRequestError", () => insert(doc.body, doc.documentElement)); + }, "If node is a host-including inclusive ancestor of parent, then throw a HierarchyRequestError DOMException."); + + // Step 4 + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + const doc2 = document.implementation.createHTMLDocument("title2"); + assert_throws_dom("HierarchyRequestError", () => insert(doc, doc2)); + }, "If node is not a DocumentFragment, DocumentType, Element, Text, ProcessingInstruction, or Comment node, then throw a HierarchyRequestError DOMException."); + + // Step 5, in case of inserting a text node into a document + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + assert_throws_dom("HierarchyRequestError", () => insert(doc, doc.createTextNode("text"))); + }, "If node is a Text node and parent is a document, then throw a HierarchyRequestError DOMException."); + + // Step 5, in case of inserting a doctype into a non-document + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + const doctype = doc.childNodes[0]; + assert_throws_dom("HierarchyRequestError", () => insert(doc.createElement("a"), doctype)); + }, "If node is a doctype and parent is not a document, then throw a HierarchyRequestError DOMException.") + + // Step 6, in case of DocumentFragment including multiple elements + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + doc.documentElement.remove(); + const df = doc.createDocumentFragment(); + df.appendChild(doc.createElement("a")); + df.appendChild(doc.createElement("b")); + assert_throws_dom("HierarchyRequestError", () => insert(doc, df)); + }, "If node is a DocumentFragment with multiple elements and parent is a document, then throw a HierarchyRequestError DOMException."); + + // Step 6, in case of DocumentFragment has multiple elements when document already has an element + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + const df = doc.createDocumentFragment(); + df.appendChild(doc.createElement("a")); + assert_throws_dom("HierarchyRequestError", () => insert(doc, df)); + }, "If node is a DocumentFragment with an element and parent is a document with another element, then throw a HierarchyRequestError DOMException."); + + // Step 6, in case of an element + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + const el = doc.createElement("a"); + assert_throws_dom("HierarchyRequestError", () => insert(doc, el)); + }, "If node is an Element and parent is a document with another element, then throw a HierarchyRequestError DOMException."); + + // Step 6, in case of a doctype when document already has another doctype + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + const doctype = doc.childNodes[0].cloneNode(); + doc.documentElement.remove(); + assert_throws_dom("HierarchyRequestError", () => insert(doc, doctype)); + }, "If node is a doctype and parent is a document with another doctype, then throw a HierarchyRequestError DOMException."); + + // Step 6, in case of a doctype when document has an element + if (methodName !== "prepend") { + // Skip `.prepend` as this doesn't throw if `child` is an element + test(() => { + const doc = document.implementation.createHTMLDocument("title"); + const doctype = doc.childNodes[0].cloneNode(); + doc.childNodes[0].remove(); + assert_throws_dom("HierarchyRequestError", () => insert(doc, doctype)); + }, "If node is a doctype and parent is a document with an element, then throw a HierarchyRequestError DOMException."); + } +} diff --git a/tests/wpt/web-platform-tests/dom/nodes/pre-insertion-checks.js b/tests/wpt/web-platform-tests/dom/nodes/pre-insertion-validation-notfound.js index 705283fa235..705283fa235 100644 --- a/tests/wpt/web-platform-tests/dom/nodes/pre-insertion-checks.js +++ b/tests/wpt/web-platform-tests/dom/nodes/pre-insertion-validation-notfound.js diff --git a/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-css.html b/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-css.html index f56260fdb45..603a60c8bba 100644 --- a/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-css.html +++ b/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-css.html @@ -8,38 +8,44 @@ <script> var request_token = token(); -async_test(t => { - window.onload = t.step_func(() => { - t.step_timeout(() => { - assert_equals(window.getComputedStyle(document.body).getPropertyValue('background-color'), "rgb(0, 128, 0)"); - var link2 = document.createElement("link"); - link2.onload = t.step_func(() => { - assert_equals(window.getComputedStyle(document.body).getPropertyValue('background-color'), "rgb(0, 128, 0)"); - var checkResult = () => { - // We poll because we don't know when the revalidation will occur. - fetch("resources/stale-css.py?query&token=" + request_token).then(t.step_func((response) => { - var count = response.headers.get("Count"); - if (count == '2') { - t.done(); - } else { - t.step_timeout(checkResult, 25); - } - })); - }; - t.step_timeout(checkResult, 25); - }); - link2.rel = "stylesheet"; - link2.type = "text/css"; - link2.href = "resources/stale-css.py?token=" + request_token; - document.body.appendChild(link2); - }, 0); - }); +let link_src = "./resources/stale-css.py?token=" + request_token; + +let loadLink = async() => { + let link = document.createElement("link"); + link.rel = "stylesheet"; + link.type = "text/css"; + link.href = "resources/stale-css.py?token=" + request_token; + let loaded = new Promise(r => link.onload = r); + document.body.appendChild(link); + await loaded; + return window + .getComputedStyle(document.body) + .getPropertyValue('background-color'); +}; + +promise_test(async t => { + await new Promise(r => window.onload = r); + + let bgColor1 = await loadLink(); + assert_equals(bgColor1, "rgb(0, 128, 0)", "(initial version loaded)"); + + let bgColor2 = await loadLink(); + assert_equals(bgColor2, "rgb(0, 128, 0)", "(stale version loaded)"); + + // Query the server again and again. At some point it must have received the + // revalidation request. We poll, because we don't know when the revalidation + // will occur. + while(true) { + await new Promise(r => step_timeout(r, 25)); + let response = await fetch(link_src + "&query"); + let count = response.headers.get("Count"); + if (count == '2') + break; + } + + let bgColor3 = await loadLink(); + assert_equals(bgColor3, "rgb(255, 0, 0)", "(revalidated version loaded)"); }, 'Cache returns stale resource'); -var link = document.createElement("link"); -link.rel = "stylesheet"; -link.type = "text/css"; -link.href = "resources/stale-css.py?token=" + request_token; -document.body.appendChild(link); </script> </body> diff --git a/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-image.html b/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-image.html index 0a08f81729d..f90e293bc40 100644 --- a/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-image.html +++ b/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-image.html @@ -14,36 +14,41 @@ See: https://html.spec.whatwg.org/#the-list-of-available-images <script> var request_token = token(); -async_test(t => { - window.onload = t.step_func(() => { - t.step_timeout(() => { - assert_equals(document.getElementById("firstimage").width, 16, "Width is 16"); - var childDocument = document.getElementById('child').contentDocument; - var img2 = childDocument.createElement("img"); - img2.onload = t.step_func(() => { - assert_equals(img2.width, 16, "image dimension"); - var checkResult = () => { - // We poll because we don't know when the revalidation will occur. - fetch("resources/stale-image.py?query&token=" + request_token).then(t.step_func((response) => { - var count = response.headers.get("Count"); - if (count == '2') { - t.done(); - } else { - t.step_timeout(checkResult, 25); - } - })); - }; - t.step_timeout(checkResult, 25); - }); - img2.src = "resources/stale-image.py?token=" + request_token; - childDocument.body.appendChild(img2); - }, 0); - }); +let image_src = "resources/stale-image.py?token=" + request_token; + +let loadImage = async () => { + let img = document.createElement("img"); + img.src = image_src; + let loaded = new Promise(r => img.onload = r); + document.body.appendChild(img); + await loaded; + return img; +}; + +promise_test(async t => { + await new Promise(r => window.onload = r); + + let img1 = await loadImage(); + assert_equals(img1.width, 16, "(initial version loaded)"); + + let img2 = await loadImage(); + assert_equals(img2.width, 16, "(stale version loaded)"); + + // Query the server again and again. At some point it must have received the + // revalidation request. We poll, because we don't know when the revalidation + // will occur. + while(true) { + await new Promise(r => step_timeout(r, 25)); + let response = await fetch(image_src + "&query"); + let count = response.headers.get("Count"); + if (count == '2') + break; + } + + let img3 = await loadImage(); + assert_equals(img3.width, 256, "(revalidated version loaded)"); + }, 'Cache returns stale resource'); -var img = document.createElement("img"); -img.src = "resources/stale-image.py?token=" + request_token; -img.id = "firstimage"; -document.body.appendChild(img); </script> </body> diff --git a/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-script.html b/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-script.html index 68793e50056..f5317482c48 100644 --- a/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-script.html +++ b/tests/wpt/web-platform-tests/fetch/stale-while-revalidate/stale-script.html @@ -6,48 +6,54 @@ <script src="/common/utils.js"></script> <body> <script> -var last_modified; -var last_modified_count = 0; -var request_token = token(); -// The script will call report via a uniquely generated ID on the subresource. -// If it is a cache hit the ID will be the same and the test will pass. +const request_token = token(); +const script_src = "./resources/stale-script.py?token=" + request_token; + +// The script above will call report() via a uniquely generated ID on the +// subresource. If it is a cache hit, the ID will be the same and +// |last_modified_count| won't be incremented. +let last_modified; +let last_modified_count = 0; function report(mod) { - if (!last_modified) { - last_modified = mod; - last_modified_count = 1; - } else if (last_modified == mod) { - last_modified_count++; - } + if (last_modified == mod) + return; + last_modified = mod; + last_modified_count++; } -async_test(t => { - window.onload = t.step_func(() => { - step_timeout(() => { - var script = document.createElement("script"); - script.src = "resources/stale-script.py?token=" + request_token; - document.body.appendChild(script); - script.onload = t.step_func(() => { - assert_equals(last_modified_count, 2, "last modified"); - var checkResult = () => { - // We poll because we don't know when the revalidation will occur. - fetch("resources/stale-script.py?query&token=" + request_token).then(t.step_func((response) => { - var count = response.headers.get("Count"); - if (count == '2') { - t.done(); - } else { - t.step_timeout(checkResult, 25); - } - })); - }; - t.step_timeout(checkResult, 25); - }); - }, 0); - }); +let loadScript = async () => { + let script = document.createElement("script"); + let script_loaded = new Promise(r => script.onload = r); + script.src = script_src; + document.body.appendChild(script); + await script_loaded; +}; + +promise_test(async t => { + await new Promise(r => window.onload = r); + + await loadScript(); + assert_equals(last_modified_count, 1, '(initial version loaded)'); + + await loadScript(); + assert_equals(last_modified_count, 1, '(stale version loaded)'); + + // Query the server again and again. At some point it must have received the + // revalidation request. We poll, because we don't know when the revalidation + // will occur. + while(true) { + await new Promise(r => step_timeout(r, 25)); + let response = await fetch(script_src + "&query"); + let count = response.headers.get("Count"); + if (count == '2') + break; + } + + await loadScript(); + assert_equals(last_modified_count, 2, '(revalidated version loaded)'); + }, 'Cache returns stale resource'); -var script = document.createElement("script"); -script.src = "resources/stale-script.py?token=" + request_token; -document.body.appendChild(script); </script> </body> diff --git a/tests/wpt/web-platform-tests/hit-test/idlharness.https.html b/tests/wpt/web-platform-tests/hit-test/idlharness.https.html new file mode 100644 index 00000000000..b7f67845470 --- /dev/null +++ b/tests/wpt/web-platform-tests/hit-test/idlharness.https.html @@ -0,0 +1,29 @@ +<!doctype html> +<title>WebXR hit-test IDL tests</title> +<link rel="help" href="https://immersive-web.github.io/hit-test/"> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="/resources/WebIDLParser.js"></script> +<script src="/resources/idlharness.js"></script> + +<script> + 'use strict'; + + idl_test( + ['hit-test'], + ['webxr', 'geometry', 'dom'], + async idl_array => { + idl_array.add_objects({ + // TODO: XRHitTestSource + // TODO: XRTransientInputHitTestSource + // TODO: XRHitTestResult + // TODO: XRTransientInputHitTestResult + XRSession: ['xrSession'], + // TODO: XRFrame + XRRay: ['new XRRay()'], + }); + + self.xrSession = await navigator.xr.requestSession("inline"); + } + ); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-delayed-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-delayed-iframe.html new file mode 100644 index 00000000000..f97f597238e --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-delayed-iframe.html @@ -0,0 +1,9 @@ +<!doctype html> +<script type=module> +window.parent.document.test.step_timeout(() => { + document.write("document.write body contents\n") + document.close(); + window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); +}, 0); +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html new file mode 100644 index 00000000000..f9f9a1c0610 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-delayed.html @@ -0,0 +1,28 @@ +<!doctype html> +<title>async document.write in a module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + // Expose {test} in the iframe for using the step_timeout helper. + document.test = t; + const iframe = document.createElement("iframe"); + + iframe.onerror = t.unreached_func("Error loading iframe"); + let onLoadWasCalled = false; + iframe.onload = t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + // Don't call the event handler another time after document.write. + iframe.onload = null; + onLoadWasCalled = true; + }); + document.addEventListener("documentWriteDone", t.step_func_done(() => { + assert_equals(iframe.onload, null); + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + })); + + iframe.src = "module-delayed-iframe.html"; + document.body.appendChild(iframe); +}); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import-iframe.html new file mode 100644 index 00000000000..672bb953d6c --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import-iframe.html @@ -0,0 +1,7 @@ +<!doctype html> +<script type=module> +(async () => { + let module = await import("./module-dynamic-import.mjs"); +})(); +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html new file mode 100644 index 00000000000..02c6b9cf8d2 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.html @@ -0,0 +1,25 @@ +<!doctype html> +<title>document.write in an imported module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + const iframe = document.createElement("iframe"); + + iframe.onerror = t.unreached_func("Error loading iframe"); + let onLoadWasCalled = false; + iframe.onload = t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + iframe.onload = null; + onLoadWasCalled = true; + }); + document.addEventListener("documentWriteDone", t.step_func_done(() => { + assert_true(onLoadWasCalled); + assert_equals(iframe.contentDocument.body.textContent, "document.write body contents\n"); + })); + + iframe.src = "module-dynamic-import-iframe.html"; + document.body.appendChild(iframe); +}); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.mjs b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.mjs new file mode 100644 index 00000000000..74d24275370 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-dynamic-import.mjs @@ -0,0 +1,4 @@ +document.write("document.write body contents\n"); +document.close(); + +window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-iframe.html index 997d1eb1a34..f8646df56b7 100644 --- a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-iframe.html +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-iframe.html @@ -1,7 +1,7 @@ <!doctype html> -<meta charset=utf-8> <script type=module> -document.write("FAIL"); +document.write("document.write body contents\n"); document.close(); +window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); </script> -PASS +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed-iframe.html new file mode 100644 index 00000000000..3ae1464653a --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed-iframe.html @@ -0,0 +1,5 @@ +<!doctype html> +<script type=module> +import "./module-static-import-delayed.mjs" +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed.html new file mode 100644 index 00000000000..498d1012a07 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed.html @@ -0,0 +1,27 @@ +<!doctype html> +<title>document.write in an imported module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + // Expose {test} in the iframe for using the step_timeout helper. + document.test = t; + const iframe = document.createElement("iframe"); + + iframe.onerror = t.unreached_func("Error loading iframe"); + let onLoadWasCalled = false; + iframe.onload = t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + iframe.onload = null; + onLoadWasCalled = true; + }); + document.addEventListener("documentWriteDone", t.step_func_done(() => { + assert_true(onLoadWasCalled); + assert_equals(iframe.contentDocument.body.textContent, "document.write body contents\n"); + })); + + iframe.src = "module-static-import-delayed-iframe.html"; + document.body.appendChild(iframe); +}); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed.mjs b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed.mjs new file mode 100644 index 00000000000..45478d6f638 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-delayed.mjs @@ -0,0 +1,5 @@ +window.parent.document.test.step_timeout(() => { + document.write("document.write body contents\n") + document.close(); + window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); +}, 0); diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-iframe.html new file mode 100644 index 00000000000..ed4f6d1c6c9 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import-iframe.html @@ -0,0 +1,5 @@ +<!doctype html> +<script type=module> +import "./module-static-import.mjs" +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import.html new file mode 100644 index 00000000000..d725854d866 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import.html @@ -0,0 +1,25 @@ +<!doctype html> +<title>document.write in an imported module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + const iframe = document.createElement("iframe"); + iframe.onerror = t.unreached_func("Error loading iframe"); + + let testEndWasCalled = false; + document.addEventListener("documentWriteDone", t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + testEndWasCalled = true; + })); + iframe.onload = t.step_func_done(() => { + assert_true(testEndWasCalled); + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + }); + + iframe.src = "module-static-import-iframe.html"; + document.body.appendChild(iframe); +}); +</script> +ß diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import.mjs b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import.mjs new file mode 100644 index 00000000000..74d24275370 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-static-import.mjs @@ -0,0 +1,4 @@ +document.write("document.write body contents\n"); +document.close(); + +window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed-iframe.html new file mode 100644 index 00000000000..68411361657 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed-iframe.html @@ -0,0 +1,14 @@ +<!doctype html> +<script type=module> +let delay = new Promise( + resolve => window.parent.document.test.step_timeout(resolve, 0)); + +delay.then(() => { + document.write("FAIL"); + document.close(); + window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); +}); + +await delay; +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html new file mode 100644 index 00000000000..f269dcbcb93 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-delayed.html @@ -0,0 +1,28 @@ +<!doctype html> +<title>document.write in an imported module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + // Expose {test} in the iframe for using the step_timeout helper. + document.test = t; + + const iframe = document.createElement("iframe"); + + iframe.onerror = t.unreached_func("Error loading iframe"); + let onLoadWasCalled = false; + iframe.onload = t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + iframe.onload = null; + onLoadWasCalled = true; + }); + document.addEventListener("documentWriteDone", t.step_func_done(() => { + assert_true(onLoadWasCalled); + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + })); + + iframe.src = "module-tla-delayed-iframe.html"; + document.body.appendChild(iframe); +}); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise-iframe.html new file mode 100644 index 00000000000..3e90fb2ea73 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise-iframe.html @@ -0,0 +1,10 @@ +<!doctype html> +<script type=module> +await new Promise(resolve => { + document.write("document.write body contents\n"); + document.close(); + window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); + resolve(); +}); +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html new file mode 100644 index 00000000000..430f874b656 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-immediate-promise.html @@ -0,0 +1,28 @@ +<!doctype html> +<title>document.write in an imported module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + // Expose {test} in the iframe for using the step_timeout helper. + document.test = t; + + const iframe = document.createElement("iframe"); + + iframe.onerror = t.unreached_func("Error loading iframe"); + let onLoadWasCalled = false; + iframe.onload = t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + iframe.onload = null; + onLoadWasCalled = true; + }); + document.addEventListener("documentWriteDone", t.step_func_done(() => { + assert_true(onLoadWasCalled); + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + })); + + iframe.src = "module-tla-immediate-promise-iframe.html"; + document.body.appendChild(iframe); +}); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import-iframe.html new file mode 100644 index 00000000000..ec4a6ed6aa2 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import-iframe.html @@ -0,0 +1,5 @@ +<!doctype html> +<script type=module> +await import("./module-tla-import.mjs"); +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html new file mode 100644 index 00000000000..f59c3c0abe7 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.html @@ -0,0 +1,24 @@ +<!doctype html> +<title>document.write in an imported module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + const iframe = document.createElement("iframe"); + + iframe.onerror = t.unreached_func("Error loading iframe"); + let testEndWasCalled = false; + document.addEventListener("documentWriteDone", t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + testEndWasCalled = true; + })); + iframe.onload = t.step_func_done(() => { + assert_true(testEndWasCalled, 'documentWriteDone event was not sent'); + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + }); + + iframe.src = "module-tla-import-iframe.html"; + document.body.appendChild(iframe); +}); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.mjs b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.mjs new file mode 100644 index 00000000000..74d24275370 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-import.mjs @@ -0,0 +1,4 @@ +document.write("document.write body contents\n"); +document.close(); + +window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise-iframe.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise-iframe.html new file mode 100644 index 00000000000..5c55bed6c07 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise-iframe.html @@ -0,0 +1,10 @@ +<!doctype html> +<script type=module> +await new Promise(resolve => { + window.parent.document.test.step_timeout(resolve, 0)); + document.write("document.write body contents\n"); + document.close(); + window.parent.document.dispatchEvent(new CustomEvent("documentWriteDone")); +}); +</script> +Initial body contents diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html new file mode 100644 index 00000000000..5fc30a8b0e7 --- /dev/null +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module-tla-promise.html @@ -0,0 +1,28 @@ +<!doctype html> +<title>document.write in an imported module</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id="log"></div> +<script> +async_test(t => { + // Expose {test} in the iframe for using the step_timeout helper. + document.test = t; + + const iframe = document.createElement("iframe"); + + iframe.onerror = t.unreached_func("Error loading iframe"); + let onLoadWasCalled = false; + iframe.onload = t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + iframe.onload = null; + onLoadWasCalled = true; + }); + document.addEventListener("documentWriteDone", t.step_func_done(() => { + assert_true(onLoadWasCalled); + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + })); + + iframe.src = "module-tla-promise-iframe.html"; + document.body.appendChild(iframe); +}); +</script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module.html b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module.html index 32f0370577a..7e970d3fd92 100644 --- a/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module.html +++ b/tests/wpt/web-platform-tests/html/webappapis/dynamic-markup-insertion/document-write/module.html @@ -7,11 +7,16 @@ <script> async_test(t => { const iframe = document.createElement("iframe"); - iframe.src = "module-iframe.html"; - document.body.appendChild(iframe); + iframe.onerror = t.unreached_func("Error loading iframe"); + document.addEventListener("documentWriteDone", t.step_func(() => { + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); + })); iframe.onload = t.step_func_done(() => { - assert_equals(iframe.contentDocument.body.textContent, "PASS\n"); + assert_equals(iframe.contentDocument.body.textContent, "Initial body contents\n"); }); + + iframe.src = "module-iframe.html"; + document.body.appendChild(iframe); }); </script> diff --git a/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/historical.window.js b/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/historical.https.window.js index c27845e6a7d..f6b9db078e0 100644 --- a/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/historical.window.js +++ b/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/historical.https.window.js @@ -8,3 +8,9 @@ assert_false(method in self.navigator); }, method + "() is removed"); }); + +test(() => { + let called = false; + self.navigator.registerProtocolHandler("web+test", "%s", { toString: () => called = true }); + assert_false(called); +}, "registerProtocolHandler has no third argument"); diff --git a/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/protocol.https.html b/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/protocol.https.html index c6fbeb65c55..18c7ad1b42b 100644 --- a/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/protocol.https.html +++ b/tests/wpt/web-platform-tests/html/webappapis/system-state-and-capabilities/the-navigator-object/protocol.https.html @@ -23,6 +23,7 @@ test(() => { /* URL argument */ const valid_urls = [ '%s', + 'foo/%s', location.href + '/%s', location.href + '#%s', location.href + '?foo=%s', @@ -69,6 +70,9 @@ const invalid_urls2 = [ 'http://foobar.example.com/%s', 'mailto:%s@example.com', 'mailto:%s', + `ftp://${location.host}/%s`, + `chrome://${location.host}/%s`, + `foo://${location.host}/%s`, ]; for (const url of invalid_urls2) { test(() => { @@ -99,6 +103,7 @@ const denylist = [ 'livescript', 'mid', 'mocha', + 'moz-icon', 'opera', 'operamail', 'res', @@ -122,11 +127,15 @@ const denylist = [ 'ssh:/', 'magnet:+', 'tel:sip', + 'foo', + 'fweb+oo', /* web+ prefixed schemes must be followed by 1+ ascii alphas */ 'web+', + 'web+1', 'web+dots.are.forbidden', 'web+dashes-are-forbidden', 'web+digits123areforbidden', + 'web+UpperCasesAreForbidden', ]; for (const scheme of denylist) { test(() => { diff --git a/tests/wpt/web-platform-tests/images/green-100x50.png b/tests/wpt/web-platform-tests/images/green-100x50.png Binary files differindex 2b7577d2689..2733836c998 100644 --- a/tests/wpt/web-platform-tests/images/green-100x50.png +++ b/tests/wpt/web-platform-tests/images/green-100x50.png diff --git a/tests/wpt/web-platform-tests/interfaces/hit-test.idl b/tests/wpt/web-platform-tests/interfaces/hit-test.idl new file mode 100644 index 00000000000..0da492883b6 --- /dev/null +++ b/tests/wpt/web-platform-tests/interfaces/hit-test.idl @@ -0,0 +1,62 @@ +// GENERATED CONTENT - DO NOT EDIT +// Content was automatically extracted by Reffy into reffy-reports +// (https://github.com/tidoust/reffy-reports) +// Source: WebXR Hit Test Module (https://immersive-web.github.io/hit-test/) + +enum XRHitTestTrackableType { + "point", + "plane", + "mesh" +}; + +dictionary XRHitTestOptionsInit { + required XRSpace space; + FrozenArray<XRHitTestTrackableType> entityTypes; + XRRay offsetRay; +}; + +dictionary XRTransientInputHitTestOptionsInit { + required DOMString profile; + FrozenArray<XRHitTestTrackableType> entityTypes; + XRRay offsetRay; +}; + +[SecureContext, Exposed=Window] +interface XRHitTestSource { + void cancel(); +}; + +[SecureContext, Exposed=Window] +interface XRTransientInputHitTestSource { + void cancel(); +}; + +[SecureContext, Exposed=Window] +interface XRHitTestResult { + XRPose? getPose(XRSpace baseSpace); +}; + +[SecureContext, Exposed=Window] +interface XRTransientInputHitTestResult { + [SameObject] readonly attribute XRInputSource inputSource; + readonly attribute FrozenArray<XRHitTestResult> results; +}; + +partial interface XRSession { + Promise<XRHitTestSource> requestHitTestSource(XRHitTestOptionsInit options); + Promise<XRTransientInputHitTestSource> requestHitTestSourceForTransientInput(XRTransientInputHitTestOptionsInit options); +}; + +partial interface XRFrame { + FrozenArray<XRHitTestResult> getHitTestResults(XRHitTestSource hitTestSource); + FrozenArray<XRTransientInputHitTestResult> getHitTestResultsForTransientInput(XRTransientInputHitTestSource hitTestSource); +}; + +[SecureContext, Exposed=Window, + Constructor(optional DOMPointInit origin, optional DOMPointInit direction), + Constructor(XRRigidTransform transform)] +interface XRRay { + [SameObject] readonly attribute DOMPointReadOnly origin; + [SameObject] readonly attribute DOMPointReadOnly direction; + [SameObject] readonly attribute Float32Array matrix; +}; diff --git a/tests/wpt/web-platform-tests/interfaces/page-lifecycle.idl b/tests/wpt/web-platform-tests/interfaces/page-lifecycle.idl new file mode 100644 index 00000000000..f3d9c1f3f56 --- /dev/null +++ b/tests/wpt/web-platform-tests/interfaces/page-lifecycle.idl @@ -0,0 +1,19 @@ +// GENERATED CONTENT - DO NOT EDIT +// Content was automatically extracted by Reffy into reffy-reports +// (https://github.com/tidoust/reffy-reports) +// Source: Page Lifecycle (https://wicg.github.io/page-lifecycle/) + +partial interface Document { + attribute EventHandler onfreeze; + attribute EventHandler onresume; + readonly attribute boolean wasDiscarded; +}; + +partial interface Client { + readonly attribute ClientLifecycleState lifecycleState; +}; + +enum ClientLifecycleState { + "active", + "frozen" +}; diff --git a/tests/wpt/web-platform-tests/interfaces/pointerevents.idl b/tests/wpt/web-platform-tests/interfaces/pointerevents.idl index f4405438632..728fff98d91 100644 --- a/tests/wpt/web-platform-tests/interfaces/pointerevents.idl +++ b/tests/wpt/web-platform-tests/interfaces/pointerevents.idl @@ -31,7 +31,7 @@ interface PointerEvent : MouseEvent { readonly attribute long twist; readonly attribute DOMString pointerType; readonly attribute boolean isPrimary; - sequence<PointerEvent> getCoalescedEvents(); + [SecureContext] sequence<PointerEvent> getCoalescedEvents(); sequence<PointerEvent> getPredictedEvents(); }; @@ -46,6 +46,7 @@ partial interface mixin GlobalEventHandlers { attribute EventHandler onlostpointercapture; attribute EventHandler onpointerdown; attribute EventHandler onpointermove; + [SecureContext] attribute EventHandler onpointerrawupdate; attribute EventHandler onpointerup; attribute EventHandler onpointercancel; attribute EventHandler onpointerover; diff --git a/tests/wpt/web-platform-tests/lint.whitelist b/tests/wpt/web-platform-tests/lint.whitelist index 526d6b765bd..42102299396 100644 --- a/tests/wpt/web-platform-tests/lint.whitelist +++ b/tests/wpt/web-platform-tests/lint.whitelist @@ -684,6 +684,7 @@ LAYOUTTESTS APIS: resources/chromium/webxr-test.js LAYOUTTESTS APIS: web-nfc/NDEFReader-document-hidden-manual.https.html LAYOUTTESTS APIS: web-nfc/NDEFReader_scan.https.html LAYOUTTESTS APIS: web-nfc/NDEFWriter_write.https.html +LAYOUTTESTS APIS: webxr/resources/webxr_util.js # Signed Exchange files have hard-coded URLs in the certUrl field WEB-PLATFORM.TEST:signed-exchange/resources/*.sxg diff --git a/tests/wpt/web-platform-tests/mimesniff/mime-types/README.md b/tests/wpt/web-platform-tests/mimesniff/mime-types/README.md index 3a2681ec74f..4b3c8138669 100644 --- a/tests/wpt/web-platform-tests/mimesniff/mime-types/README.md +++ b/tests/wpt/web-platform-tests/mimesniff/mime-types/README.md @@ -1,4 +1,4 @@ -== MIME types == +## MIME types `resources/mime-types.json` and `resources/generated-mime-types.json` contain MIME type tests. The tests are encoded as a JSON array. String values in the array serve as documentation. All other values are objects with the following fields: @@ -29,3 +29,14 @@ function isByteCompatible(str) { `resources/generated-mime-types.json` is generated by running `resources/generated-mime-types.py`. Modify the latter to correct the former. These tests are used by resources in this directory to test various aspects of MIME types. + +## MIME type groups + +`resources/mime-groups.json` contains MIME type group-membership tests. The tests are encoded as a JSON array. String values in the array serve as documentation. All other values are objects with the following fields: + +* `input`: The MIME type to test. +* `groups`: An array of zero or more groups to which the MIME type belongs. + +In order to pass the tests an implementation must treat each MIME type as belonging to the exact set of groups listed, with no additions or omissions. + +Note: As MIME type groups are used only while determining the computed MIME type of a resource and are not exposed in any API, no browser-based test harness is available. diff --git a/tests/wpt/web-platform-tests/mimesniff/mime-types/resources/mime-groups.json b/tests/wpt/web-platform-tests/mimesniff/mime-types/resources/mime-groups.json new file mode 100644 index 00000000000..1b5d7d54f88 --- /dev/null +++ b/tests/wpt/web-platform-tests/mimesniff/mime-types/resources/mime-groups.json @@ -0,0 +1,159 @@ +[ + {"input": "x/x", "groups": []}, + {"input": "image/x", "groups": ["image"]}, + {"input": "audio/x", "groups": ["audio or video"]}, + {"input": "video/x", "groups": ["audio or video"]}, + {"input": "application/ogg", "groups": ["audio or video"]}, + {"input": "application/ogg;x=x", "groups": ["audio or video"]}, + {"input": "font/x", "groups": ["font"]}, + {"input": "application/font-cff", "groups": ["font"]}, + {"input": "application/font-cff;x=x", "groups": ["font"]}, + {"input": "application/font-off", "groups": ["font"]}, + {"input": "application/font-off;x=x", "groups": ["font"]}, + {"input": "application/font-sfnt", "groups": ["font"]}, + {"input": "application/font-sfnt;x=x", "groups": ["font"]}, + {"input": "application/font-ttf", "groups": ["font"]}, + {"input": "application/font-ttf;x=x", "groups": ["font"]}, + {"input": "application/font-woff", "groups": ["font"]}, + {"input": "application/font-woff;x=x", "groups": ["font"]}, + {"input": "application/vnd.ms-fontobject", "groups": ["font"]}, + {"input": "application/vnd.ms-fontobject;x=x", "groups": ["font"]}, + {"input": "application/vnd.ms-opentype", "groups": ["font"]}, + {"input": "application/vnd.ms-opentype;x=x", "groups": ["font"]}, + {"input": "x/x+zip", "groups": ["ZIP-based"]}, + {"input": "x/x+zip;x=x", "groups": ["ZIP-based"]}, + {"input": "x/+zip", "groups": ["ZIP-based"]}, + {"input": "x/+zip;x=x", "groups": ["ZIP-based"]}, + "application/zip also matches the archive group", + {"input": "application/zip", "groups": ["ZIP-based", "archive"]}, + {"input": "application/zip;x=x", "groups": ["ZIP-based", "archive"]}, + {"input": "application/x-rar-compressed", "groups": ["archive"]}, + {"input": "application/x-rar-compressed;x=x", "groups": ["archive"]}, + {"input": "application/x-gzip", "groups": ["archive"]}, + {"input": "application/x-gzip;x=x", "groups": ["archive"]}, + "XML is also scriptable", + {"input": "x/x+xml", "groups": ["XML", "scriptable"]}, + {"input": "x/x+xml;x=x", "groups": ["XML", "scriptable"]}, + {"input": "x/+xml", "groups": ["XML", "scriptable"]}, + {"input": "x/+xml;x=x", "groups": ["XML", "scriptable"]}, + {"input": "application/xml", "groups": ["XML", "scriptable"]}, + {"input": "application/xml;x=x", "groups": ["XML", "scriptable"]}, + {"input": "text/xml", "groups": ["XML", "scriptable"]}, + {"input": "text/xml;x=x", "groups": ["XML", "scriptable"]}, + "HTML is scriptable", + {"input": "text/html", "groups": ["HTML", "scriptable"]}, + {"input": "text/html;x=x", "groups": ["HTML", "scriptable"]}, + "PDF is scriptable", + {"input": "application/pdf", "groups": ["scriptable"]}, + {"input": "application/pdf;x=x", "groups": ["scriptable"]}, + {"input": "application/ecmascript", "groups": ["JavaScript"]}, + {"input": "application/ecmascript;x=x", "groups": ["JavaScript"]}, + {"input": "application/javascript", "groups": ["JavaScript"]}, + {"input": "application/javascript;x=x", "groups": ["JavaScript"]}, + {"input": "application/x-ecmascript", "groups": ["JavaScript"]}, + {"input": "application/x-ecmascript;x=x", "groups": ["JavaScript"]}, + {"input": "application/x-javascript", "groups": ["JavaScript"]}, + {"input": "application/x-javascript;x=x", "groups": ["JavaScript"]}, + {"input": "text/ecmascript", "groups": ["JavaScript"]}, + {"input": "text/ecmascript;x=x", "groups": ["JavaScript"]}, + {"input": "text/javascript", "groups": ["JavaScript"]}, + {"input": "text/javascript;x=x", "groups": ["JavaScript"]}, + {"input": "text/javascript1.0", "groups": ["JavaScript"]}, + {"input": "text/javascript1.0;x=x", "groups": ["JavaScript"]}, + {"input": "text/javascript1.1", "groups": ["JavaScript"]}, + {"input": "text/javascript1.1;x=x", "groups": ["JavaScript"]}, + {"input": "text/javascript1.2", "groups": ["JavaScript"]}, + {"input": "text/javascript1.2;x=x", "groups": ["JavaScript"]}, + {"input": "text/javascript1.3", "groups": ["JavaScript"]}, + {"input": "text/javascript1.3;x=x", "groups": ["JavaScript"]}, + {"input": "text/javascript1.4", "groups": ["JavaScript"]}, + {"input": "text/javascript1.4;x=x", "groups": ["JavaScript"]}, + {"input": "text/javascript1.5", "groups": ["JavaScript"]}, + {"input": "text/javascript1.5;x=x", "groups": ["JavaScript"]}, + {"input": "text/jscript", "groups": ["JavaScript"]}, + {"input": "text/jscript;x=x", "groups": ["JavaScript"]}, + {"input": "text/livescript", "groups": ["JavaScript"]}, + {"input": "text/livescript;x=x", "groups": ["JavaScript"]}, + {"input": "text/x-ecmascript", "groups": ["JavaScript"]}, + {"input": "text/x-ecmascript;x=x", "groups": ["JavaScript"]}, + {"input": "text/x-javascript", "groups": ["JavaScript"]}, + {"input": "text/x-javascript;x=x", "groups": ["JavaScript"]}, + {"input": "x/x+json", "groups": ["JSON"]}, + {"input": "x/x+json;x=x", "groups": ["JSON"]}, + {"input": "x/+json", "groups": ["JSON"]}, + {"input": "x/+json;x=x", "groups": ["JSON"]}, + {"input": "application/json", "groups": ["JSON"]}, + {"input": "application/json;x=x", "groups": ["JSON"]}, + {"input": "text/json", "groups": ["JSON"]}, + {"input": "text/json;x=x", "groups": ["JSON"]}, + {"input": "x/x;type=image", "groups": []}, + {"input": "x/x;type=audio", "groups": []}, + {"input": "x/x;type=video", "groups": []}, + {"input": "x/x;type=font", "groups": []}, + {"input": "ximage/x", "groups": []}, + {"input": "xaudio/x", "groups": []}, + {"input": "xvideo/x", "groups": []}, + {"input": "xfont/x", "groups": []}, + {"input": "imagex/x", "groups": []}, + {"input": "audiox/x", "groups": []}, + {"input": "videox/x", "groups": []}, + {"input": "fontx/x", "groups": []}, + {"input": "x/image", "groups": []}, + {"input": "x/png", "groups": []}, + {"input": "x/audio", "groups": []}, + {"input": "x/video", "groups": []}, + {"input": "x/ogg", "groups": []}, + {"input": "x/font", "groups": []}, + {"input": "x/woff", "groups": []}, + {"input": "x/font-ttf", "groups": []}, + {"input": "x/x;x=\"application/font-ttf\"", "groups": []}, + {"input": "x/zip", "groups": []}, + {"input": "x/x-gzip", "groups": []}, + {"input": "x/x-rar-compressed", "groups": []}, + {"input": "x/x;x=\"application/x-gip\"", "groups": []}, + {"input": "x+zip/x", "groups": []}, + {"input": "x/x;x=x+zip", "groups": []}, + {"input": "x/x;subtype=x+zip", "groups": []}, + {"input": "x/xml", "groups": []}, + {"input": "x/x;x=\"application/xml\"", "groups": []}, + {"input": "x+xml/x", "groups": []}, + {"input": "x/x;x=x+xml", "groups": []}, + {"input": "x/x;subtype=x+xml", "groups": []}, + {"input": "x/pdf", "groups": []}, + {"input": "x/html", "groups": []}, + {"input": "x/ecmascript", "groups": []}, + {"input": "x/javascript", "groups": []}, + {"input": "x/x-ecmascript", "groups": []}, + {"input": "x/x-javascript", "groups": []}, + {"input": "x/jscript", "groups": []}, + {"input": "x/livescript", "groups": []}, + {"input": "x/javascript1.0", "groups": []}, + {"input": "x/javascript1.1", "groups": []}, + {"input": "x/javascript1.2", "groups": []}, + {"input": "x/javascript1.3", "groups": []}, + {"input": "x/javascript1.4", "groups": []}, + {"input": "x/javascript1.5", "groups": []}, + {"input": "x/x;x=\"application/javascript\"", "groups": []}, + {"input": "x/json", "groups": []}, + {"input": "x/x;x=\"application/json\"", "groups": []}, + {"input": "x+json/x", "groups": []}, + {"input": "x/x;x=x+json", "groups": []}, + {"input": "x/x;subtype=x+json", "groups": []}, + {"input": "image/png", "groups": ["image"]}, + {"input": "audio/mp4", "groups": ["audio or video"]}, + {"input": "video/mpeg", "groups": ["audio or video"]}, + {"input": "font/woff", "groups": ["font"]}, + "SVG is both image and XML, thus also scriptable", + {"input": "image/svg+xml", "groups": ["image", "XML", "scriptable"]}, + "Hypothetical SVG font type", + {"input": "font/svg+xml", "groups": ["font", "XML", "scriptable"]}, + "XHTML is not considered HTML", + {"input": "application/xhtml+xml", "groups": ["XML", "scriptable"]}, + "Subtype longer than 255", + {"input": "x/01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789+zip", + "groups": ["ZIP-based"]}, + {"input": "x/01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789+xml", + "groups": ["XML", "scriptable"]}, + {"input": "x/01234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789+json", + "groups": ["JSON"]} +] diff --git a/tests/wpt/web-platform-tests/native-file-system/sandboxed_FileSystemBaseHandle-IndexedDB.tentative.https.any.js b/tests/wpt/web-platform-tests/native-file-system/sandboxed_FileSystemBaseHandle-IndexedDB.tentative.https.any.js index 6610810eb99..7f0fc4a7212 100644 --- a/tests/wpt/web-platform-tests/native-file-system/sandboxed_FileSystemBaseHandle-IndexedDB.tentative.https.any.js +++ b/tests/wpt/web-platform-tests/native-file-system/sandboxed_FileSystemBaseHandle-IndexedDB.tentative.https.any.js @@ -3,4 +3,4 @@ // META: script=resources/messaging-helpers.js // META: script=resources/messaging-serialize-helpers.js // META: script=/IndexedDB/support-promises.js -// META: script=script-tests/FileSystemBaseHandle-IndexedDB.js
\ No newline at end of file +// META: script=script-tests/FileSystemBaseHandle-IndexedDB.js diff --git a/tests/wpt/web-platform-tests/offscreen-canvas/green-100x50.png b/tests/wpt/web-platform-tests/offscreen-canvas/green-100x50.png Binary files differdeleted file mode 100644 index 2733836c998..00000000000 --- a/tests/wpt/web-platform-tests/offscreen-canvas/green-100x50.png +++ /dev/null diff --git a/tests/wpt/web-platform-tests/page-lifecycle/idlharness.html b/tests/wpt/web-platform-tests/page-lifecycle/idlharness.html new file mode 100644 index 00000000000..08b2b054fba --- /dev/null +++ b/tests/wpt/web-platform-tests/page-lifecycle/idlharness.html @@ -0,0 +1,22 @@ +<!doctype html> +<title>Page Lifecycle IDL tests</title> +<link rel="help" href="https://wicg.github.io/page-lifecycle/"> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="/resources/WebIDLParser.js"></script> +<script src="/resources/idlharness.js"></script> + +<script> + 'use strict'; + + idl_test( + ['page-lifecycle'], + ['service-workers', 'html', 'dom'], + idl_array => { + idl_array.add_objects({ + Document: ['document'], + // TODO: Client. + }); + } + ); +</script> diff --git a/tests/wpt/web-platform-tests/performance-timeline/webtiming-resolution.any.js b/tests/wpt/web-platform-tests/performance-timeline/webtiming-resolution.any.js index 46e0489352f..d869c7c52d5 100644 --- a/tests/wpt/web-platform-tests/performance-timeline/webtiming-resolution.any.js +++ b/tests/wpt/web-platform-tests/performance-timeline/webtiming-resolution.any.js @@ -22,4 +22,4 @@ function timeByUserTiming() { } testTimeResolution(timeByPerformanceNow, 'performance.now()'); -testTimeResolution(timeByUserTiming, 'entry.startTime');
\ No newline at end of file +testTimeResolution(timeByUserTiming, 'entry.startTime'); diff --git a/tests/wpt/web-platform-tests/pointerevents/idlharness.window.js b/tests/wpt/web-platform-tests/pointerevents/idlharness.window.js index 89a994af304..90e81259825 100644 --- a/tests/wpt/web-platform-tests/pointerevents/idlharness.window.js +++ b/tests/wpt/web-platform-tests/pointerevents/idlharness.window.js @@ -7,9 +7,10 @@ idl_test( ['pointerevents'], - ['uievents', 'dom', 'html'], + ['uievents', 'html', 'dom'], idl_array => { idl_array.add_objects({ + Document: ['document'], Element: ['document'], Window: ['window'], Navigator: ['navigator'], diff --git a/tests/wpt/web-platform-tests/resource-timing/buffered-flag.any.js b/tests/wpt/web-platform-tests/resource-timing/buffered-flag.any.js index 63a386159f3..b46fd00e69d 100644 --- a/tests/wpt/web-platform-tests/resource-timing/buffered-flag.any.js +++ b/tests/wpt/web-platform-tests/resource-timing/buffered-flag.any.js @@ -15,4 +15,4 @@ async_test(t => { })).observe({'type': 'resource', buffered: true}); }).observe({'entryTypes': ['resource']}); fetch('resources/empty.js'); -}, 'PerformanceObserver with buffered flag sees previous resource entries.');
\ No newline at end of file +}, 'PerformanceObserver with buffered flag sees previous resource entries.'); diff --git a/tests/wpt/web-platform-tests/service-workers/service-worker/ServiceWorkerGlobalScope/fetch-on-the-right-interface.https.any.js b/tests/wpt/web-platform-tests/service-workers/service-worker/ServiceWorkerGlobalScope/fetch-on-the-right-interface.https.any.js index 9a9c8198057..44946d43b62 100644 --- a/tests/wpt/web-platform-tests/service-workers/service-worker/ServiceWorkerGlobalScope/fetch-on-the-right-interface.https.any.js +++ b/tests/wpt/web-platform-tests/service-workers/service-worker/ServiceWorkerGlobalScope/fetch-on-the-right-interface.https.any.js @@ -11,4 +11,4 @@ test(function() { assert_equals(self.fetch, self.__proto__.__proto__.fetch, 'ServiceWorkerGlobalScope.fetch should be the same as ' + 'WorkerGlobalScope.fetch.'); -}, 'Fetch method on the right interface');
\ No newline at end of file +}, 'Fetch method on the right interface'); diff --git a/tests/wpt/web-platform-tests/speech-api/SpeechSynthesis-speak-ownership.html b/tests/wpt/web-platform-tests/speech-api/SpeechSynthesis-speak-ownership.html deleted file mode 100644 index 269017af692..00000000000 --- a/tests/wpt/web-platform-tests/speech-api/SpeechSynthesis-speak-ownership.html +++ /dev/null @@ -1,27 +0,0 @@ -<!doctype html> -<script src="/resources/testharness.js"></script> -<script src="/resources/testharnessreport.js"></script> -<script src="/resources/testdriver.js"></script> -<script src="/resources/testdriver-vendor.js"></script> -<iframe></iframe> -<script> -// using an utterance for different SpeechSynthesis instances should throw -async_test(t => { - test_driver.bless('speechSynthesis.speak', t.step_func_done(() => { - // the utterance is short to make the test faster - const utter = new SpeechSynthesisUtterance('1'); - const iframe = document.querySelector('iframe'); - assert_not_equals(speechSynthesis, iframe.contentWindow.speechSynthesis); - speechSynthesis.speak(utter); - // the spec doesn't say what exception to throw: - // https://github.com/w3c/speech-api/issues/8 - let threw = false; - try { - iframe.contentWindow.speechSynthesis.speak(utter); - } catch (e) { - threw = true; - } - assert_true(threw); - })); -}, 'Using the same SpeechSynthesisUtterance with two SpeechSynthesis instances'); -</script> diff --git a/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/browsers/firefox.py b/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/browsers/firefox.py index bfc3ab9a2be..9532bd03cb7 100644 --- a/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/browsers/firefox.py +++ b/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/browsers/firefox.py @@ -272,6 +272,9 @@ class FirefoxInstanceManager(object): if self.enable_webrender: env["MOZ_WEBRENDER"] = "1" env["MOZ_ACCELERATED"] = "1" + # Set MOZ_X_SYNC and GDK_SYNCHRONIZE for investigation; bug 1625250. + env["MOZ_X_SYNC"] = "1" + env["GDK_SYNCHRONIZE"] = "1" else: env["MOZ_WEBRENDER"] = "0" diff --git a/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/testloader.py b/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/testloader.py index c559c94debc..78967371537 100644 --- a/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/testloader.py +++ b/tests/wpt/web-platform-tests/tools/wptrunner/wptrunner/testloader.py @@ -359,6 +359,10 @@ class SingleTestSource(TestSource): return test_queue + @classmethod + def tests_by_group(cls, tests, **kwargs): + return {cls.group_metadata(None)['scope']: [t.id for t in tests]} + class PathGroupedSource(GroupedSource): @classmethod diff --git a/tests/wpt/web-platform-tests/uievents/order-of-events/focus-events/focus-management-expectations.html b/tests/wpt/web-platform-tests/uievents/order-of-events/focus-events/focus-management-expectations.html new file mode 100644 index 00000000000..1845c15d716 --- /dev/null +++ b/tests/wpt/web-platform-tests/uievents/order-of-events/focus-events/focus-management-expectations.html @@ -0,0 +1,48 @@ +<!DOCTYPE html> +<html> + +<head> + <meta charset="utf-8"> + <title>Focus management event expectations</title> + <link rel="author" title="Mu-An Chiou" href="https://muan.co"> + <link rel="help" href="https://w3c.github.io/uievents/#event-flow-activation"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="/resources/testdriver.js"></script> + <script src="/resources/testdriver-actions.js"></script> + <script src="/resources/testdriver-vendor.js"></script> +</head> + +<body> + <button type="button" id="fromEl">Focus management from button</button> + <button type="button" id="toEl">To button</button> + <button type="button" id="EndTestEl">End test button</button> +</body> + +<script> + const from = document.getElementById("fromEl") + const to = document.getElementById("toEl") + const endTest = document.getElementById("EndTestEl") + + from.addEventListener("keydown", function (event) { + if (event.key === " ") to.focus() + }) + + async_test(function (t) { + let buttonFocused = false + to.addEventListener("click", t.unreached_func("Button should not be clicked")) + to.addEventListener("focus", () => buttonFocused = true) + endTest.addEventListener('click', () => { + assert_true(buttonFocused, "Button should be focused") + t.step_timeout(() => t.done(), 200) + }) + + // execute test + from.focus() + new test_driver.Actions().keyDown("\ue00d").keyUp("\ue00d").send().then(() => + new test_driver.click(endTest) + ) + }, "Keydown to focus should not trigger activation") +</script> + +</html>
\ No newline at end of file diff --git a/tests/wpt/web-platform-tests/webrtc/RTCPeerConnection-operations.https.html b/tests/wpt/web-platform-tests/webrtc/RTCPeerConnection-operations.https.html index a0921d315a3..28ae3afcd73 100644 --- a/tests/wpt/web-platform-tests/webrtc/RTCPeerConnection-operations.https.html +++ b/tests/wpt/web-platform-tests/webrtc/RTCPeerConnection-operations.https.html @@ -248,10 +248,38 @@ promise_test(async t => { t.add_cleanup(() => pc.close()); const transceiver = pc.addTransceiver("audio"); await new Promise(r => pc.onnegotiationneeded = r); - assert_false(await isOperationsChainEmpty(pc), "Empty chain"); + assert_true(await isOperationsChainEmpty(pc), "Empty chain"); await new Promise(r => t.step_timeout(r, 0)); assert_true(await isOperationsChainEmpty(pc), "Empty chain"); -}, "Firing of negotiationneeded uses operations chain"); +}, "Firing of negotiationneeded does NOT use operations chain"); + +promise_test(async t => { + const pc1 = new RTCPeerConnection(); + t.add_cleanup(() => pc1.close()); + const pc2 = new RTCPeerConnection(); + t.add_cleanup(() => pc2.close()); + + pc1.addTransceiver("audio"); + pc1.addTransceiver("video"); + const offer = await pc1.createOffer(); + await pc1.setLocalDescription(offer); + const candidates = []; + for (let c; (c = (await new Promise(r => pc1.onicecandidate = r)).candidate);) { + candidates.push(c); + } + pc2.addTransceiver("video"); + let fired = false; + const p = new Promise(r => pc2.onnegotiationneeded = () => r(fired = true)); + await Promise.all([ + pc2.setRemoteDescription(offer), + ...candidates.map(candidate => pc2.addIceCandidate(candidate)), + pc2.setLocalDescription() + ]); + assert_false(fired, "Negotiationneeded mustn't have fired yet."); + await new Promise(r => t.step_timeout(r, 0)); + assert_true(fired, "Negotiationneeded must have fired by now."); + await p; +}, "Negotiationneeded only fires once operations chain is empty"); promise_test(async t => { const pc = new RTCPeerConnection(); diff --git a/tests/wpt/web-platform-tests/webrtc/RTCPeerConnection-perfect-negotiation.https.html b/tests/wpt/web-platform-tests/webrtc/RTCPeerConnection-perfect-negotiation.https.html new file mode 100644 index 00000000000..ad2725c33ca --- /dev/null +++ b/tests/wpt/web-platform-tests/webrtc/RTCPeerConnection-perfect-negotiation.https.html @@ -0,0 +1,186 @@ +<!doctype html> +<meta charset=utf-8> +<meta name="timeout" content="long"> +<title></title> +<script src=/resources/testharness.js></script> +<script src=/resources/testharnessreport.js></script> +<script> +'use strict'; + +function peer(other, polite, fail = null) { + const send = (tgt, msg) => tgt.postMessage(JSON.parse(JSON.stringify(msg)), + "*"); + if (!fail) fail = e => send(window.parent, {error: `${e.name}: ${e.message}`}); + const pc = new RTCPeerConnection(); + + if (!window.assert_equals) { + window.assert_equals = (a, b, msg) => a === b || + fail(new Error(`${msg} expected ${b} but got ${a}`)); + } + + const commands = { + async addTransceiver() { + const transceiver = pc.addTransceiver("video"); + await new Promise(r => pc.addEventListener("negotiated", r, {once: true})); + if (!transceiver.currentDirection) { + // Might have just missed the negotiation train. Catch next one. + await new Promise(r => pc.addEventListener("negotiated", r, {once: true})); + } + assert_equals(transceiver.currentDirection, "sendonly", "have direction"); + return pc.getTransceivers().length; + }, + async simpleConnect() { + const p = commands.addTransceiver(); + await new Promise(r => pc.oniceconnectionstatechange = + () => pc.iceConnectionState == "connected" && r()); + return await p; + }, + async getNumTransceivers() { + return pc.getTransceivers().length; + }, + }; + + try { + pc.addEventListener("icecandidate", ({candidate}) => send(other, + {candidate})); + let makingOffer = false, ignoreOffer = false; + pc.addEventListener("negotiationneeded", async () => { + try { + assert_equals(pc.signalingState, "stable", "negotiationneeded always fires in stable state"); + assert_equals(makingOffer, false, "negotiationneeded not already in progress"); + makingOffer = true; + await pc.setLocalDescription(); + assert_equals(pc.signalingState, "have-local-offer", "negotiationneeded not racing with onmessage"); + assert_equals(pc.localDescription.type, "offer", "negotiationneeded SLD worked"); + send(other, {description: pc.localDescription}); + } catch (e) { + fail(e); + } finally { + makingOffer = false; + } + }); + window.onmessage = async ({data: {description, candidate, run}}) => { + try { + if (description) { + ignoreOffer = description.type == "offer" && !polite && + (makingOffer || pc.signalingState != "stable"); + if (ignoreOffer) { + return; + } + await pc.setRemoteDescription(description); + if (description.type == "offer") { + assert_equals(pc.signalingState, "have-remote-offer", "Remote offer"); + assert_equals(pc.remoteDescription.type, "offer", "SRD worked"); + await pc.setLocalDescription(); + assert_equals(pc.signalingState, "stable", "onmessage not racing with negotiationneeded"); + assert_equals(pc.localDescription.type, "answer", "onmessage SLD worked"); + send(other, {description: pc.localDescription}); + } else { + assert_equals(pc.remoteDescription.type, "answer", "Answer was set"); + assert_equals(pc.signalingState, "stable", "answered"); + pc.dispatchEvent(new Event("negotiated")); + } + } else if (candidate) { + try { + await pc.addIceCandidate(candidate); + } catch (e) { + if (!ignoreOffer) throw e; + } + } else if (run) { + send(window.parent, {[run.id]: await commands[run.cmd]() || 0}); + } + } catch (e) { + fail(e); + } + }; + } catch (e) { + fail(e); + } + return pc; +} + +async function setupPeerIframe(t, polite) { + const iframe = document.createElement("iframe"); + t.add_cleanup(() => iframe.remove()); + iframe.srcdoc = + `<html\><script\>(${peer.toString()})(window.parent, ${polite});</script\></html\>`; + document.documentElement.appendChild(iframe); + + const failCatcher = t.step_func(({data}) => + ("error" in data) && assert_unreached(`Error in iframe: ${data.error}`)); + window.addEventListener("message", failCatcher); + t.add_cleanup(() => window.removeEventListener("message", failCatcher)); + await new Promise(r => iframe.onload = r); + return iframe; +} + +function setupPeerTopLevel(t, other, polite) { + const pc = peer(other, polite, t.step_func(e => { throw e; })); + t.add_cleanup(() => { pc.close(); window.onmessage = null; }); +} + +let counter = 0; +async function run(target, cmd) { + const id = `result${counter++}`; + target.postMessage({run: {cmd, id}}, "*"); + return new Promise(r => window.addEventListener("message", + function listen({data}) { + if (!(id in data)) return; + window.removeEventListener("message", listen); + r(data[id]); + })); +} + +let iframe; +async function setupAB(t, politeA, politeB) { + iframe = await setupPeerIframe(t, politeB); + return setupPeerTopLevel(t, iframe.contentWindow, politeA); +} +const runA = cmd => run(window, cmd); +const runB = cmd => run(iframe.contentWindow, cmd); +const runBoth = (cmdA, cmdB = cmdA) => Promise.all([runA(cmdA), runB(cmdB)]); + +async function promise_test_both_roles(f, name) { + promise_test(async t => f(t, await setupAB(t, true, false)), name); + promise_test(async t => f(t, await setupAB(t, false, true)), + `${name} with roles reversed`); +} + +promise_test_both_roles(async (t, pc) => { + assert_equals(await runA("simpleConnect"), 1, "one transceiver"); + assert_equals(await runB("addTransceiver"), 2, "two transceivers"); +}, "Perfect negotiation setup connects"); + +promise_test_both_roles(async (t, pc) => { + await runBoth("addTransceiver"); + const [numA, numB] = await runBoth("getNumTransceivers"); + assert_equals(numA, 2, "two transceivers on side A"); + assert_equals(numB, 2, "two transceivers on side B"); +}, "Perfect negotiation glare"); + +promise_test_both_roles(async (t, pc) => { + const ps = []; + for (let i = 20; i > 0; i--) { + ps.push(runBoth("addTransceiver")); + await new Promise(r => t.step_timeout(r, i - 1)); + } + ps.push(runBoth("addTransceiver")); + await Promise.all(ps); + const [numA, numB] = await runBoth("getNumTransceivers"); + assert_equals(numA, 42, "42 transceivers on side A"); + assert_equals(numB, 42, "42 transceivers on side B"); +}, "Perfect negotiation stress glare"); + +promise_test_both_roles(async (t, pc) => { + const ps = []; + for (let i = 20; i > 0; i--) { + ps.push(runBoth("addTransceiver")); + await new Promise(r => t.step_timeout(r, 0)); + } + ps.push(runBoth("addTransceiver")); + await Promise.all(ps); + const [numA, numB] = await runBoth("getNumTransceivers"); + assert_equals(numA, 42, "42 transceivers on side A"); + assert_equals(numB, 42, "42 transceivers on side B"); +}, "Perfect negotiation stress glare linear"); +</script> diff --git a/tests/wpt/web-platform-tests/webxr/resources/webxr_util.js b/tests/wpt/web-platform-tests/webxr/resources/webxr_util.js index c9f7e81b094..65c39844b15 100644 --- a/tests/wpt/web-platform-tests/webxr/resources/webxr_util.js +++ b/tests/wpt/web-platform-tests/webxr/resources/webxr_util.js @@ -22,6 +22,11 @@ function xr_promise_test(name, func, properties) { xr_debug = navigator.xr.test.Debug; } + if (self.internals && internals.xrTest && navigator.xr) { + // WebKit setup + await setupWebKitWebXRTestAPI; + } + // Ensure that any devices are disconnected when done. If this were done in // a .then() for the success case, a test that expected failure would // already be marked done at the time that runs and the shutdown would @@ -199,3 +204,16 @@ let loadChromiumResources = Promise.resolve().then(() => { return chain; }); + +let setupWebKitWebXRTestAPI = Promise.resolve().then(() => { + if (!self.internals) { + // Do nothing on non-WebKit-based browsers. + return; + } + + // WebKit setup. The internals object is used by the WebKit test runner + // to provide JS access to internal APIs. In this case it's used to + // ensure that XRTest is only exposed to wpt tests. + navigator.xr.test = internals.xrTest; + return Promise.resolve(); +}); diff --git a/tests/wpt/web-platform-tests/wpt.py b/tests/wpt/web-platform-tests/wpt.py index affba7343ea..c38fe78e917 100644 --- a/tests/wpt/web-platform-tests/wpt.py +++ b/tests/wpt/web-platform-tests/wpt.py @@ -1,3 +1,7 @@ # This file exists to allow `python wpt <command>` to work on Windows: -# https://github.com/web-platform-tests/wpt/pull/6907 +# https://github.com/web-platform-tests/wpt/pull/6907 and +# https://github.com/web-platform-tests/wpt/issues/23095 +import os +abspath = os.path.abspath(__file__) +os.chdir(os.path.dirname(abspath)) exec(compile(open("wpt", "r").read(), "wpt", 'exec')) diff --git a/tests/wpt/web-platform-tests/xhr/event-abort.any.js b/tests/wpt/web-platform-tests/xhr/event-abort.any.js index 9b38ccf9c9e..5b17ece0085 100644 --- a/tests/wpt/web-platform-tests/xhr/event-abort.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-abort.any.js @@ -12,4 +12,4 @@ test.step(function () { test.step_timeout(() => { assert_unreached("onabort not called after 4 ms"); }, 4); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-error.sub.any.js b/tests/wpt/web-platform-tests/xhr/event-error.sub.any.js index df63dc05bfa..62a158cdcfb 100644 --- a/tests/wpt/web-platform-tests/xhr/event-error.sub.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-error.sub.any.js @@ -10,4 +10,4 @@ async_test(function (t) { client.open("GET", "http://nonexistent.{{host}}:{{ports[http][0]}}"); client.send("null"); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-load.any.js b/tests/wpt/web-platform-tests/xhr/event-load.any.js index 72e46a5cea8..dcb92cc980d 100644 --- a/tests/wpt/web-platform-tests/xhr/event-load.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-load.any.js @@ -18,4 +18,4 @@ test.step(function () { }); client.open("GET", "resources/well-formed.xml"); client.send(null); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-loadend.any.js b/tests/wpt/web-platform-tests/xhr/event-loadend.any.js index 7bd1844b378..16087b52967 100644 --- a/tests/wpt/web-platform-tests/xhr/event-loadend.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-loadend.any.js @@ -16,4 +16,4 @@ test.step(function () { }; client.open("GET", "resources/well-formed.xml"); client.send(null); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-loadstart-upload.any.js b/tests/wpt/web-platform-tests/xhr/event-loadstart-upload.any.js index 0f41cd1286b..3918adb66a9 100644 --- a/tests/wpt/web-platform-tests/xhr/event-loadstart-upload.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-loadstart-upload.any.js @@ -16,4 +16,4 @@ test.step(function () { }); client.open("POST", "resources/trickle.py?ms=5&count=8"); client.send('foo=bar'); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-loadstart.any.js b/tests/wpt/web-platform-tests/xhr/event-loadstart.any.js index 4778404a00e..55af4c31631 100644 --- a/tests/wpt/web-platform-tests/xhr/event-loadstart.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-loadstart.any.js @@ -14,4 +14,4 @@ test.step(function () { }, 500); client.open("GET", "resources/well-formed.xml"); client.send(null); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-progress.any.js b/tests/wpt/web-platform-tests/xhr/event-progress.any.js index 0e7c3a42c7d..094d3618117 100644 --- a/tests/wpt/web-platform-tests/xhr/event-progress.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-progress.any.js @@ -15,4 +15,4 @@ test.step(function () { }); client.open("GET", "resources/trickle.py?count=4&delay=150"); client.send(null); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-readystate-sync-open.any.js b/tests/wpt/web-platform-tests/xhr/event-readystate-sync-open.any.js index 321635e7dea..a8a4fe7f9a1 100644 --- a/tests/wpt/web-platform-tests/xhr/event-readystate-sync-open.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-readystate-sync-open.any.js @@ -20,4 +20,4 @@ test(function () { } client.open('GET', "...", true) assert_array_equals(eventsFired, [1]) -}, title + ' (async)');
\ No newline at end of file +}, title + ' (async)'); diff --git a/tests/wpt/web-platform-tests/xhr/event-readystatechange-loaded.any.js b/tests/wpt/web-platform-tests/xhr/event-readystatechange-loaded.any.js index 1e4467aaebd..a33e6f89227 100644 --- a/tests/wpt/web-platform-tests/xhr/event-readystatechange-loaded.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-readystatechange-loaded.any.js @@ -20,4 +20,4 @@ test.step(function () { client.open("GET", "resources/trickle.py?count=10"); // default timeout in trickle.py is 1/2 sec, so this request will take 5 seconds to complete client.send(null); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-timeout-order.any.js b/tests/wpt/web-platform-tests/xhr/event-timeout-order.any.js index b35e908a9d8..55319814a90 100644 --- a/tests/wpt/web-platform-tests/xhr/event-timeout-order.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-timeout-order.any.js @@ -18,4 +18,4 @@ test.step(function () { test.step_timeout(() => { assert_unreached("ontimeout not called."); }, 10); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-timeout.any.js b/tests/wpt/web-platform-tests/xhr/event-timeout.any.js index d114b08b3e1..da8ca11bb8e 100644 --- a/tests/wpt/web-platform-tests/xhr/event-timeout.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-timeout.any.js @@ -15,4 +15,4 @@ test.step(function () { test.step_timeout(() => { assert_unreached("ontimeout not called."); }, 10); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-upload-progress-crossorigin.any.js b/tests/wpt/web-platform-tests/xhr/event-upload-progress-crossorigin.any.js index 1036f2b14f0..9f4c44aabe7 100644 --- a/tests/wpt/web-platform-tests/xhr/event-upload-progress-crossorigin.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-upload-progress-crossorigin.any.js @@ -23,4 +23,4 @@ const remote = get_host_info().HTTP_REMOTE_ORIGIN + "/xhr/resources/corsenabled. client.upload.onloadstart = test.unreached_func(); // registered too late client.upload.onprogress = test.unreached_func(); // registered too late }, "Upload events registered too late (" + url + ")"); -});
\ No newline at end of file +}); diff --git a/tests/wpt/web-platform-tests/xhr/event-upload-progress.any.js b/tests/wpt/web-platform-tests/xhr/event-upload-progress.any.js index 5d1546757ba..87223c172d5 100644 --- a/tests/wpt/web-platform-tests/xhr/event-upload-progress.any.js +++ b/tests/wpt/web-platform-tests/xhr/event-upload-progress.any.js @@ -23,4 +23,4 @@ const remote = get_host_info().HTTP_REMOTE_ORIGIN + "/xhr/resources/corsenabled. client.upload.onloadstart = test.unreached_func(); // registered too late client.upload.onprogress = test.unreached_func(); // registered too late }, "Upload events registered too late (" + url + ")"); -});
\ No newline at end of file +}); diff --git a/tests/wpt/webgl/meta/conformance2/rendering/draw-buffers.html.ini b/tests/wpt/webgl/meta/conformance2/rendering/draw-buffers.html.ini index dd299c6c0c2..2fb72d9c465 100644 --- a/tests/wpt/webgl/meta/conformance2/rendering/draw-buffers.html.ini +++ b/tests/wpt/webgl/meta/conformance2/rendering/draw-buffers.html.ini @@ -83,3 +83,24 @@ [WebGL test #40: attachment 3 should be 0,255,0,255\nat (0, 0) expected: 0,255,0,255 was 0,0,255,0] expected: FAIL + [WebGL test #48: attachment 3 should be 0,255,0,255\nat (0, 0) expected: 0,255,0,255 was 0,255,0,0] + expected: FAIL + + [WebGL test #44: attachment 7 should be 0,255,0,255\nat (4, 0) expected: 0,255,0,255 was 255,255,0,0] + expected: FAIL + + [WebGL test #49: attachment 4 should be 0,255,0,255\nat (0, 0) expected: 0,255,0,255 was 23,0,0,0] + expected: FAIL + + [WebGL test #43: attachment 6 should be 0,255,0,255\nat (0, 0) expected: 0,255,0,255 was 255,0,0,255] + expected: FAIL + + [WebGL test #52: attachment 7 should be 0,255,0,255\nat (0, 0) expected: 0,255,0,255 was 255,0,255,255] + expected: FAIL + + [WebGL test #51: attachment 6 should be 0,255,0,255\nat (0, 0) expected: 0,255,0,255 was 255,0,0,255] + expected: FAIL + + [WebGL test #42: attachment 5 should be 0,255,0,255\nat (0, 0) expected: 0,255,0,255 was 0,255,0,0] + expected: FAIL + |