Auto merge of #20886 - servo-wpt-sync:wpt_update_30-05-2018, r=jdm

Sync WPT with upstream (30-05-2018)

Automated downstream sync of changes from upstream as of 30-05-2018.
[no-wpt-sync]

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/20886)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-05-30 23:32:33 -04:00 committed by GitHub
commit b0dd1c839a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
72 changed files with 1286 additions and 1091 deletions

View file

@ -11161,6 +11161,12 @@
{}
]
],
"feature-policy/experimental-features/vertical-scroll-touch-block-manual.tentative.html": [
[
"/feature-policy/experimental-features/vertical-scroll-touch-block-manual.tentative.html",
{}
]
],
"fullscreen/api/document-exit-fullscreen-manual.html": [
[
"/fullscreen/api/document-exit-fullscreen-manual.html",
@ -11353,6 +11359,12 @@
{}
]
],
"fullscreen/api/promises-resolve-manual.html": [
[
"/fullscreen/api/promises-resolve-manual.html",
{}
]
],
"fullscreen/model/move-to-fullscreen-iframe-manual.html": [
[
"/fullscreen/model/move-to-fullscreen-iframe-manual.html",
@ -108900,7 +108912,79 @@
"/css/css-contain/contain-paint-013.html",
[
[
"/css/css-contain/contain-paint-013-ref.html",
"/css/css-contain/reference/contain-paint-013-ref.html",
"=="
]
],
{}
]
],
"css/css-contain/contain-paint-014.html": [
[
"/css/css-contain/contain-paint-014.html",
[
[
"/css/css-contain/reference/contain-paint-014-ref.html",
"=="
]
],
{}
]
],
"css/css-contain/contain-paint-015.html": [
[
"/css/css-contain/contain-paint-015.html",
[
[
"/css/css-contain/reference/contain-size-001-ref.html",
"=="
]
],
{}
]
],
"css/css-contain/contain-paint-016.html": [
[
"/css/css-contain/contain-paint-016.html",
[
[
"/css/css-contain/reference/contain-size-001-ref.html",
"=="
]
],
{}
]
],
"css/css-contain/contain-paint-017.html": [
[
"/css/css-contain/contain-paint-017.html",
[
[
"/css/css-contain/reference/contain-size-001-ref.html",
"=="
]
],
{}
]
],
"css/css-contain/contain-paint-018.html": [
[
"/css/css-contain/contain-paint-018.html",
[
[
"/css/css-contain/reference/contain-size-001-ref.html",
"=="
]
],
{}
]
],
"css/css-contain/contain-paint-019.html": [
[
"/css/css-contain/contain-paint-019.html",
[
[
"/css/css-contain/reference/contain-paint-014-ref.html",
"=="
]
],
@ -124815,6 +124899,18 @@
{}
]
],
"css/css-multicol/orthogonal-writing-mode-shrink-to-fit.html": [
[
"/css/css-multicol/orthogonal-writing-mode-shrink-to-fit.html",
[
[
"/css/reference/ref-filled-green-100px-square.xht",
"=="
]
],
{}
]
],
"css/css-multicol/zero-column-width-layout.html": [
[
"/css/css-multicol/zero-column-width-layout.html",
@ -149327,6 +149423,18 @@
{}
]
],
"css/css-ui/outline-020.html": [
[
"/css/css-ui/outline-020.html",
[
[
"/css/css-ui/reference/outline-020-ref.html",
"=="
]
],
{}
]
],
"css/css-ui/outline-color-001.html": [
[
"/css/css-ui/outline-color-001.html",
@ -239925,11 +240033,6 @@
{}
]
],
"css/css-contain/contain-paint-013-ref.html": [
[
{}
]
],
"css/css-contain/contain-style-counters-ref.html": [
[
{}
@ -239975,6 +240078,16 @@
{}
]
],
"css/css-contain/reference/contain-paint-013-ref.html": [
[
{}
]
],
"css/css-contain/reference/contain-paint-014-ref.html": [
[
{}
]
],
"css/css-contain/reference/contain-size-001-ref.html": [
[
{}
@ -258590,6 +258703,11 @@
{}
]
],
"css/css-ui/reference/outline-020-ref.html": [
[
{}
]
],
"css/css-ui/reference/outline-offset.html": [
[
{}
@ -266015,6 +266133,11 @@
{}
]
],
"css/tools/README.md": [
[
{}
]
],
"css/tools/apiclient/.gitignore": [
[
{}
@ -266075,51 +266198,6 @@
{}
]
],
"css/tools/html2xhtml.py": [
[
{}
]
],
"css/tools/list-all.pl": [
[
{}
]
],
"css/tools/list-all.sh": [
[
{}
]
],
"css/tools/make-html.py": [
[
{}
]
],
"css/tools/supportprop.py": [
[
{}
]
],
"css/tools/templates/filename-list.tmpl": [
[
{}
]
],
"css/tools/travis/LICENSE": [
[
{}
]
],
"css/tools/travis/build.py": [
[
{}
]
],
"css/tools/travis/vcs.py": [
[
{}
]
],
"css/tools/w3ctestlib/.hgignore": [
[
{}
@ -272980,6 +273058,11 @@
{}
]
],
"feature-policy/experimental-features/resources/vertical-scroll-touch-block.html": [
[
{}
]
],
"feature-policy/experimental-features/resources/vertical-scroll.js": [
[
{}
@ -287315,6 +287398,11 @@
{}
]
],
"interfaces/input-events.idl": [
[
{}
]
],
"interfaces/keyboard-lock.idl": [
[
{}
@ -287330,11 +287418,21 @@
{}
]
],
"interfaces/media-capabilities.idl": [
[
{}
]
],
"interfaces/mediacapture-main.idl": [
[
{}
]
],
"interfaces/mediasession.idl": [
[
{}
]
],
"interfaces/orientation-sensor.idl": [
[
{}
@ -287385,11 +287483,6 @@
{}
]
],
"interfaces/staticrange.idl": [
[
{}
]
],
"interfaces/storage.idl": [
[
{}
@ -330733,6 +330826,12 @@
{}
]
],
"fullscreen/api/promises-reject.html": [
[
"/fullscreen/api/promises-reject.html",
{}
]
],
"fullscreen/interfaces.html": [
[
"/fullscreen/interfaces.html",
@ -334643,6 +334742,18 @@
{}
]
],
"html/rendering/non-replaced-elements/tables/form-in-tables.html": [
[
"/html/rendering/non-replaced-elements/tables/form-in-tables.html",
{}
]
],
"html/rendering/non-replaced-elements/tables/form-in-tables.xhtml": [
[
"/html/rendering/non-replaced-elements/tables/form-in-tables.xhtml",
{}
]
],
"html/rendering/non-replaced-elements/tables/table-vspace-hspace-s.html": [
[
"/html/rendering/non-replaced-elements/tables/table-vspace-hspace-s.html",
@ -339291,6 +339402,12 @@
{}
]
],
"html/semantics/interactive-elements/the-dialog-element/dialog-showModal-remove.html": [
[
"/html/semantics/interactive-elements/the-dialog-element/dialog-showModal-remove.html",
{}
]
],
"html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html": [
[
"/html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html",
@ -367793,12 +367910,6 @@
{}
]
],
"staticrange/idlharness.html": [
[
"/staticrange/idlharness.html",
{}
]
],
"storage/estimate-indexeddb-worker.https.html": [
[
"/storage/estimate-indexeddb-worker.https.html",
@ -398485,7 +398596,7 @@
"support"
],
"./.gitmodules": [
"525f7d93f00f11086aabc1f652cf06623e21986c",
"6a203e28d43909d7513daf8761281b351d2b2bd7",
"support"
],
"./.pyup.yml": [
@ -489581,7 +489692,7 @@
"reftest"
],
"css/build-css-testsuites.sh": [
"0f1d955402449b61d134265ea5962d6ed93836f4",
"f08c6940dff13aad1b6c5fc81c08abcaa8aafc67",
"support"
],
"css/compositing/Blending_in_a_group_with_filter-ref.html": [
@ -495224,12 +495335,32 @@
"6a0fe4f463f20f38b800aa4218814efe72c99f2e",
"reftest"
],
"css/css-contain/contain-paint-013-ref.html": [
"c3d8d642f2b4b25df84170669222b61866ab3057",
"support"
],
"css/css-contain/contain-paint-013.html": [
"a53186c648e33d9978c4abbd4bc7c4ed79c860c8",
"9d34bde07da1bcd1d8cb7e65cb35bafca7b6eef4",
"reftest"
],
"css/css-contain/contain-paint-014.html": [
"c22ee90cf05992dab4188cc86c255bd040babe26",
"reftest"
],
"css/css-contain/contain-paint-015.html": [
"3941644b7fffc11a2786e55dc28d6fcfe55c57dc",
"reftest"
],
"css/css-contain/contain-paint-016.html": [
"fbedca7cd40c2e5a6aea020de403d81ea334f2c1",
"reftest"
],
"css/css-contain/contain-paint-017.html": [
"40a82207bac0728925609faf19e0aa896f956009",
"reftest"
],
"css/css-contain/contain-paint-018.html": [
"74f65ae0e2f8c4ceb77c54fa8bf9b1d364f55c38",
"reftest"
],
"css/css-contain/contain-paint-019.html": [
"75b780b1b791b6c3c06cddbd9462103b88bbd603",
"reftest"
],
"css/css-contain/contain-size-001.html": [
@ -495341,7 +495472,15 @@
"support"
],
"css/css-contain/reference/contain-paint-008-ref.html": [
"9148bb5f9f1f4bfa70a056e0d744ffddad909c7d",
"deba6dbd69a33458e0ae5de8721ae10984864dc6",
"support"
],
"css/css-contain/reference/contain-paint-013-ref.html": [
"c3d8d642f2b4b25df84170669222b61866ab3057",
"support"
],
"css/css-contain/reference/contain-paint-014-ref.html": [
"1f281c10ae1bf7dd0f1c9119458b3698077a8e60",
"support"
],
"css/css-contain/reference/contain-size-001-ref.html": [
@ -512864,6 +513003,10 @@
"81373bbae307e030054a54a6685793ae794e07f0",
"reftest"
],
"css/css-multicol/orthogonal-writing-mode-shrink-to-fit.html": [
"d98ec8f37d130bd984ff3814e9644d4d8427385d",
"reftest"
],
"css/css-multicol/reference/multicol-basic-005-ref.xht": [
"84948b72576a31ee25b4e945404c831d5f1d0293",
"support"
@ -531672,6 +531815,10 @@
"343127ab9431a804a3d5484c4dbaad2a2dae8c05",
"reftest"
],
"css/css-ui/outline-020.html": [
"38588f278a3795effa0b77b3e65a35a344bf85f1",
"reftest"
],
"css/css-ui/outline-color-001.html": [
"ce0a7c0301b2d8b8d1f521b69fb987ff39d0ff3a",
"reftest"
@ -531840,6 +531987,10 @@
"c27aa0f4b78e0d388f90b1e54d19db72780b9c26",
"support"
],
"css/css-ui/reference/outline-020-ref.html": [
"2491d5c730fa27be0257aa10147c249824d32edd",
"support"
],
"css/css-ui/reference/outline-offset.html": [
"e2af3bbb57ba940e1dcfedc70f03c3281c259350",
"support"
@ -544308,6 +544459,10 @@
"7301f0ec4d66b71a92818aa3d532c5eca718f677",
"support"
],
"css/tools/README.md": [
"17dc12660a62726b5975e125cefb1cc42b007b6f",
"support"
],
"css/tools/apiclient/.gitignore": [
"4f8c72d787595386529108512329027d424dad47",
"support"
@ -544356,42 +544511,6 @@
"9dc0b6f869b328886b153eee2dd0b0053cd712e2",
"support"
],
"css/tools/html2xhtml.py": [
"abaf4dec00fa3b29f556f35700410775acd63395",
"support"
],
"css/tools/list-all.pl": [
"27670ddc5a347fa2d0608483875294f8f4957b07",
"support"
],
"css/tools/list-all.sh": [
"040b805bb924cd18077cc07f7a449067d7fc0cd7",
"support"
],
"css/tools/make-html.py": [
"3fb558bb57627987e143d415d8677508a2dfbaf2",
"support"
],
"css/tools/supportprop.py": [
"92973da4c183e497ef7b4a888ca929216073f9ea",
"support"
],
"css/tools/templates/filename-list.tmpl": [
"ddcb87e03b20a95d9b10ad00bbb1228e3fd5a9ba",
"support"
],
"css/tools/travis/LICENSE": [
"0ea78bfe20b327310471cc22618f7c921c6e0481",
"support"
],
"css/tools/travis/build.py": [
"470c482e0463459a3d0b48af0107a2429a281db8",
"support"
],
"css/tools/travis/vcs.py": [
"715959f81edaae4a2ac5ad6a16dbb045c199074f",
"support"
],
"css/tools/w3ctestlib/.hgignore": [
"68a4744eda8cfd5d6313a91e1468cffacf37b61f",
"support"
@ -544469,7 +544588,7 @@
"support"
],
"css/tools/w3ctestlib/templates/index.content.tmpl": [
"c9195c8e9ed930d37c3a64f65c0b43f1cb3d6fc0",
"44523077ae83bbed046402999ab32dd27d4809b6",
"support"
],
"css/tools/w3ctestlib/templates/index.htm.tmpl": [
@ -558356,6 +558475,10 @@
"a85e54c23c9e055c959a86187d07f1c0d943f37d",
"support"
],
"feature-policy/experimental-features/resources/vertical-scroll-touch-block.html": [
"b0574f00487af6997cbec51eed426bada4912bcf",
"support"
],
"feature-policy/experimental-features/resources/vertical-scroll.js": [
"a62c440428fe22a7afd4d8174e47dfc483c7de90",
"support"
@ -558380,6 +558503,10 @@
"32f1b7eacf4de1d7d792bb27ca439636c242c29c",
"manual"
],
"feature-policy/experimental-features/vertical-scroll-touch-block-manual.tentative.html": [
"ae88b77a9d913ee830fc4a84cf1e4007942c63fb",
"manual"
],
"feature-policy/feature-policy-frame-policy-allowed-for-all.https.sub.html": [
"a48c092204750e00c9aa167a9ef9d2d239445d22",
"testharness"
@ -560453,7 +560580,7 @@
"manual"
],
"fullscreen/api/document-exit-fullscreen-twice-manual.html": [
"c6e9696b4cfdef6a7042ccbe9beaddf8c56d8031",
"d017b67adff16d1dad2195763bbe88e741ee47ad",
"manual"
],
"fullscreen/api/document-fullscreen-element-manual.html": [
@ -560477,7 +560604,7 @@
"manual"
],
"fullscreen/api/document-onfullscreenerror.html": [
"ed8836f302fffdaa407bf9bf7799effa17fb6823",
"1dd69713aaa8030892e68cfb0fec2fccb8863723",
"testharness"
],
"fullscreen/api/element-ready-check-allowed-cross-origin-manual.sub.html": [
@ -560549,7 +560676,7 @@
"manual"
],
"fullscreen/api/element-request-fullscreen-not-allowed.html": [
"8991e8df530fa7c24a9e084f2ab17fa9c70fb120",
"5eac634c56810200d4c6a8b1c3c6f547ba1e7dc9",
"testharness"
],
"fullscreen/api/element-request-fullscreen-null-ns-manual.html": [
@ -560569,7 +560696,7 @@
"manual"
],
"fullscreen/api/element-request-fullscreen-timing-manual.html": [
"4ecd76a2ef773172d45f656f52a7358be2a4568d",
"48df66c401edcba47d1336313833a24d5e3d211d",
"manual"
],
"fullscreen/api/element-request-fullscreen-top-manual.html": [
@ -560592,6 +560719,14 @@
"9d9bec938f185b2461da4d00a5683ad5d07ee577",
"testharness"
],
"fullscreen/api/promises-reject.html": [
"2bc121b4bc0a397f2f25c5fca1aa32fa8727b776",
"testharness"
],
"fullscreen/api/promises-resolve-manual.html": [
"ec9276eb2b2ab279a84aa06a644b4333e46e970d",
"manual"
],
"fullscreen/api/resources/attempt-fullscreen.html": [
"33e277b3f06677f14eed442ecce76b408e7e006e",
"support"
@ -560609,31 +560744,31 @@
"manual"
],
"fullscreen/model/move-to-iframe-manual.html": [
"818cb1b5db729db4959591dc75d4bb1ae3c7542d",
"7d591d11ce4a399156ed7cae7ddbee93aa8cb883",
"manual"
],
"fullscreen/model/move-to-inactive-document-manual.html": [
"552d65141acc2221e8407316c02e0d4cf17db7eb",
"e3f8160bd2457bfb2797f85aed082f865ae6ad78",
"manual"
],
"fullscreen/model/remove-child-manual.html": [
"b1142930c6c972057213bd477cf116fcc9e7fc2a",
"0b19b1bbb6040b4ca6280bba0f742680856c5b9a",
"manual"
],
"fullscreen/model/remove-first-manual.html": [
"3de98ae96822370fa80c1b8d61df254910a63ff9",
"b694dcf40492ec67239f19152779794acde3fe4a",
"manual"
],
"fullscreen/model/remove-last-manual.html": [
"8caa21a892edeaba9996a7f2bf1c670385e0a91b",
"5c425c386688bf38a8b26ba25c43923e128db88e",
"manual"
],
"fullscreen/model/remove-parent-manual.html": [
"e5791db04ab5e2b75a00c922457fcc8ba87c7ce7",
"c0f0103c9e4491ef04b016f7bbacd8564ea5493d",
"manual"
],
"fullscreen/model/remove-single-manual.html": [
"c7fc8323d503adb6d7f0c390a8add90c5c9e8082",
"64bf88ae3a1a3708dfe823d85f67636ae5b0d736",
"manual"
],
"fullscreen/rendering/fullscreen-pseudo-class-manual.html": [
@ -560649,7 +560784,7 @@
"manual"
],
"fullscreen/trusted-click.js": [
"e401e8e8bcd97446991398d6021a9bd712c923c5",
"069f4d40fbcb4e933d4f651d3220820836615660",
"support"
],
"gamepad/OWNERS": [
@ -570844,6 +570979,14 @@
"1732dc6dd595354e21c7fb6006c32b844ceedf18",
"reftest"
],
"html/rendering/non-replaced-elements/tables/form-in-tables.html": [
"8319c136723513a019d48f66c663ce3673777bcd",
"testharness"
],
"html/rendering/non-replaced-elements/tables/form-in-tables.xhtml": [
"610932708cb18b8022ca64b8c9f3f59d8cf1ae56",
"testharness"
],
"html/rendering/non-replaced-elements/tables/table-border-1-ref.html": [
"1f3aa494ba434211a8cdcd1be289e702856fa05a",
"support"
@ -576244,6 +576387,10 @@
"529cf6c2cf2daf031f7d41aef93e6f5645e30ec2",
"testharness"
],
"html/semantics/interactive-elements/the-dialog-element/dialog-showModal-remove.html": [
"86aef9d34903bf33c036cd8eabb4078b98cbe4d9",
"testharness"
],
"html/semantics/interactive-elements/the-dialog-element/dialog-showModal.html": [
"c00ac5b6d038b45b1a7cfbef94a4527757fa74e6",
"testharness"
@ -580801,7 +580948,7 @@
"support"
],
"input-events/idlharness.html": [
"cd25518dd402033694667ccd1982fd3b85faa412",
"51c7e4864c9ec4ce110cacbfc4cad2114f5eae01",
"testharness"
],
"input-events/input-events-cut-paste-manual.html": [
@ -580960,6 +581107,10 @@
"fe86c7370a537be87884d1b9da1f7b7630c6af41",
"support"
],
"interfaces/input-events.idl": [
"99bcfa971e6b2628ab8ba174b772d56b23dee38b",
"support"
],
"interfaces/keyboard-lock.idl": [
"7188a9233db3acc741650d46156e16e9e7a132fa",
"support"
@ -580972,10 +581123,18 @@
"ffac480912edba82886fef6d5368092d237a0c7f",
"support"
],
"interfaces/media-capabilities.idl": [
"17413896d6281553091cf2c369c29de42d450962",
"support"
],
"interfaces/mediacapture-main.idl": [
"3400c775504ebf32af3f8e1165a53ca60f258495",
"support"
],
"interfaces/mediasession.idl": [
"7cbe73f7f563ee45772bb466ce63e16a549548d3",
"support"
],
"interfaces/orientation-sensor.idl": [
"1f0698a8611726b1ba724a5d7a0961e836c7b07e",
"support"
@ -581016,10 +581175,6 @@
"3b2cb524838f2274463664621fddc7c927ac95af",
"support"
],
"interfaces/staticrange.idl": [
"32069e14ad423a85d087ee335c50a379ea591b34",
"support"
],
"interfaces/storage.idl": [
"7c3221be9fdf6be4965cf5aeca2063f93c2110d6",
"support"
@ -581921,7 +582076,7 @@
"testharness"
],
"media-capabilities/idlharness.html": [
"396430dee8bc806e95a218e03f767b34efe8fe83",
"47b8077cfff98cf07d5794ab32974ed4bc8d8a01",
"testharness"
],
"media-source/OWNERS": [
@ -582493,7 +582648,7 @@
"testharness"
],
"mediacapture-record/OWNERS": [
"07b087d69286825ceefa9cefa47aa0a49605cad2",
"11b5b5a5f4b18030f80101a98f90bb43808a1061",
"support"
],
"mediacapture-record/idlharness.html": [
@ -582541,7 +582696,7 @@
"testharness"
],
"mediacapture-streams/MediaDevices-getUserMedia.https.html": [
"dbd2cbacb24f088167e1c34207bea12c19f5d0e1",
"2e54bc378625fb8fa2c6c36722ee2d09a3e88729",
"testharness"
],
"mediacapture-streams/MediaStream-MediaElement-preload-none-manual.https.html": [
@ -582645,7 +582800,7 @@
"support"
],
"mediasession/idlharness.html": [
"8db3276ecfd3f02e55b89171f61e45e6af540614",
"96a3bd3eb15a373ca1c68d528ff6514b3d7cddc1",
"testharness"
],
"mediasession/mediametadata.html": [
@ -600241,7 +600396,7 @@
"testharness"
],
"resource-timing/resource_initiator_types.html": [
"b05a2dfad953398d6b31f11055606f2f3694a9af",
"7cb0db4825afda3877fc183279adc58dca0399ea",
"testharness"
],
"resource-timing/resource_memory_cached.sub.html": [
@ -604376,10 +604531,6 @@
"45bfdcce349e2cb28611520b006c060347fdf58d",
"testharness"
],
"staticrange/idlharness.html": [
"233d7056716b753962c9e7f84a02cd72de31b7e3",
"testharness"
],
"storage/OWNERS": [
"2c585ecaee5e62118d3cb98c98e12d959ebcbd50",
"support"
@ -618501,7 +618652,7 @@
"support"
],
"workers/opaque-origin.html": [
"ea9b3b24c0e95ff424bb9d381b36b06df5891d30",
"7e9c9a1eab7ae17002aff672f863ed172609cf5e",
"testharness"
],
"workers/postMessage_DataCloneErr.htm": [

View file

@ -38,6 +38,3 @@
[Test @font-face matching for weight 249]
expected: FAIL
[Test @font-face matching for weight 420]
expected: FAIL

View file

@ -1,2 +0,0 @@
[vh_not_refreshing_on_chrome.html]
expected: FAIL

View file

@ -0,0 +1,4 @@
[document-onfullscreenerror.html]
[Document#onfullscreenerror]
expected: FAIL

View file

@ -30,3 +30,6 @@
[Set HTTP URL frame location.protocol to data]
expected: FAIL
[Set HTTP URL frame location.protocol to x]
expected: FAIL

View file

@ -1,4 +0,0 @@
[010.html]
[Salvagability of document.opened document]
expected: FAIL

View file

@ -0,0 +1,4 @@
[form-in-tables.html]
[UA style for form in table elements]
expected: FAIL

View file

@ -0,0 +1,4 @@
[form-in-tables.xhtml]
[UA style for form in table elements - XHTML]
expected: FAIL

View file

@ -172,3 +172,63 @@
[XHTML img usemap="http://example.org/#garbage-before-hash-id"]
expected: FAIL
[HTML (quirks) IMG usemap="no-hash-name"]
expected: FAIL
[HTML (quirks) IMG usemap="no-hash-id"]
expected: FAIL
[HTML (quirks) IMG usemap="hash-last#"]
expected: FAIL
[HTML (quirks) IMG usemap=""]
expected: FAIL
[HTML (quirks) IMG usemap="#"]
expected: FAIL
[HTML (quirks) IMG usemap="#percent-escape-name-%41"]
expected: FAIL
[HTML (quirks) IMG usemap="#percent-escape-id-%41"]
expected: FAIL
[HTML (quirks) IMG usemap="#no-such-map"]
expected: FAIL
[HTML (quirks) IMG usemap="#different-CASE-name"]
expected: FAIL
[HTML (quirks) IMG usemap="#different-CASE-id"]
expected: FAIL
[XHTML img usemap="no-hash-name"]
expected: FAIL
[XHTML img usemap="no-hash-id"]
expected: FAIL
[XHTML img usemap="hash-last#"]
expected: FAIL
[XHTML img usemap=""]
expected: FAIL
[XHTML img usemap="#"]
expected: FAIL
[XHTML img usemap="#percent-escape-name-%41"]
expected: FAIL
[XHTML img usemap="#percent-escape-id-%41"]
expected: FAIL
[XHTML img usemap="#no-such-map"]
expected: FAIL
[XHTML img usemap="#different-CASE-name"]
expected: FAIL
[XHTML img usemap="#different-CASE-id"]
expected: FAIL

View file

@ -0,0 +1,4 @@
[dialog-showModal-remove.html]
[dialog element: removing from document after showModal()]
expected: FAIL

View file

@ -1,4 +1,4 @@
[shader-uniform-packing-restrictions.html]
[context-creation-and-destruction.html]
expected: TIMEOUT
[Overall test]
expected: NOTRUN

View file

@ -0,0 +1,2 @@
[context-eviction-with-garbage-collection.html]
expected: TIMEOUT

View file

@ -1,4 +1,4 @@
[rapid-resizing.html]
[context-release-upon-reload.html]
expected: TIMEOUT
[Overall test]
expected: NOTRUN

View file

@ -1,9 +1,3 @@
[submodule "css/tools/apiclient"]
path = css/tools/apiclient
url = https://github.com/w3c/csswg-apiclient.git
[submodule "css/tools/w3ctestlib"]
path = css/tools/w3ctestlib
url = https://github.com/w3c/csswg-w3ctestlib.git
[submodule "tools/html5lib/html5lib/tests/testdata"]
path = tools/html5lib/html5lib/tests/testdata
url = https://github.com/html5lib/html5lib-tests.git

View file

@ -41,12 +41,6 @@ main() {
# Install dependencies
$VENV/bin/pip install -r requirements.txt
# Error if submodules are not there
if [ ! -d tools/apiclient -o ! -d tools/w3ctestlib ]; then
echo 'Please run `git submodule update --init --recursive`'
exit 1
fi
# Run the build script
$VENV/bin/python tools/build.py "$@"
}

View file

@ -3,7 +3,7 @@
<title>CSS Containment Test: Paint containment independent formatting context</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-paint">
<link rel="match" href="contain-paint-013-ref.html">
<link rel="match" href="reference/contain-paint-013-ref.html">
<meta name=assert content="Paint containment elements establish an independent formatting context. The test checks that this feature of paint containment applies to blocks and inline blocks, but it doesn't apply to inline elements.">
<style>
.wrapper {

View file

@ -0,0 +1,19 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Containment Test: Paint containment on table-cell</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-paint">
<link rel="match" href="reference/contain-paint-014-ref.html">
<meta name=assert content="Paint containment does apply to table-cell elements.">
<style>
div {
display: table-cell;
contain: paint;
}
span {
position: absolute;
}
</style>
<p>This test passes if you can NOT see the word FAIL below.</p>
<div><span>FAIL</span></div>

View file

@ -0,0 +1,19 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Containment Test: Paint containment on table-row-group</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-paint">
<link rel="match" href="reference/contain-size-001-ref.html">
<meta name=assert content="Paint containment doesn't apply to table-row-group elements.">
<style>
div {
display: table-row-group;
contain: paint;
}
span {
position: absolute;
}
</style>
<p>This test passes if you can see the word PASS below.</p>
<div><span>PASS</span></div>

View file

@ -0,0 +1,19 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Containment Test: Paint containment on table-header-group</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-paint">
<link rel="match" href="reference/contain-size-001-ref.html">
<meta name=assert content="Paint containment doesn't apply to table-header-group elements.">
<style>
div {
display: table-header-group;
contain: paint;
}
span {
position: absolute;
}
</style>
<p>This test passes if you can see the word PASS below.</p>
<div><span>PASS</span></div>

View file

@ -0,0 +1,19 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Containment Test: Paint containment on table-footer-group</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-paint">
<link rel="match" href="reference/contain-size-001-ref.html">
<meta name=assert content="Paint containment doesn't apply to table-footer-group elements.">
<style>
div {
display: table-footer-group;
contain: paint;
}
span {
position: absolute;
}
</style>
<p>This test passes if you can see the word PASS below.</p>
<div><span>PASS</span></div>

View file

@ -0,0 +1,19 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Containment Test: Paint containment on table-row</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-paint">
<link rel="match" href="reference/contain-size-001-ref.html">
<meta name=assert content="Paint containment doesn't apply to table-row elements.">
<style>
div {
display: table-row;
contain: paint;
}
span {
position: absolute;
}
</style>
<p>This test passes if you can see the word PASS below.</p>
<div><span>PASS</span></div>

View file

@ -0,0 +1,19 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Containment Test: Paint containment on table-caption</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<link rel="help" href="https://drafts.csswg.org/css-contain-1/#containment-paint">
<link rel="match" href="reference/contain-paint-014-ref.html">
<meta name=assert content="Paint containment does apply to table-caption elements.">
<style>
div {
display: table-caption;
contain: paint;
}
span {
position: absolute;
}
</style>
<p>This test passes if you can NOT see the word FAIL below.</p>
<div><span>FAIL</span></div>

View file

@ -8,11 +8,9 @@
rt {
display: ruby-text;
font-size: 1rem;
position: relative;
left: 4ch;
font-family: monospace;
}
</style>
<p>This test passes if you can see the word PASS below.
<div><ruby><rt>PASS</rt></ruby></div>
<div><ruby><rt><span style="margin-left: 4ch;"></span>PASS</rt></ruby></div>

View file

@ -0,0 +1,5 @@
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Containment Test: Reference file</title>
<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com">
<p>This test passes if you can NOT see the word FAIL below.</p>

View file

@ -0,0 +1,13 @@
<!DOCTYPE html>
<title>Orthogonal writing mode root inside shrink-to-fit multicol container</title>
<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
<link rel="help" href="https://www.w3.org/TR/css-sizing-3/#intrinsic-sizes" title="4.1. Intrinsic Sizes">
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div style="width:100px; height:100px; background:red;">
<div style="float:left; columns:1; column-gap:0; height:100px; background:green;">
<div style="writing-mode:vertical-rl;">
<div style="width:100px; height:100px;"></div>
</div>
</div>
</div>

View file

@ -0,0 +1,23 @@
<!doctype html>
<html lang=en>
<meta charset=utf-8>
<title>CSS-UI test: outline block with outline inline</title>
<link rel="author" title="Aleks Totic <atotic@chromium.org>" href="atotic@">
<meta name=assert content="">
<link rel=help href="https://drafts.csswg.org/css-ui-3/#outline-props">
<link rel="match" href="./reference/outline-020-ref.html">
<style>
#container {
outline: green solid 5px;
width: 100px;
height: 30px;
padding: 5px;
}
#target {
outline: blue solid 5px;
}
</style>
<p>Test passes if blue outline touches top left of green outline.</p>
<div id="container"><span id="target">x</span></div>

View file

@ -0,0 +1,26 @@
<!doctype html>
<html lang=en>
<meta charset=utf-8>
<title>CSS-UI test: outline block with outline inline reference file</title>
<link rel="author" title="Aleks Totic <atotic@chromium.org>">
<meta name=assert content="inline child displays outline correctly">
<style>
#container {
border: 5px solid green;
width: 110px;
height: 40px;
position: relative;
top: -5px;
left: -5px;
}
#target {
border: 5px solid blue;
position: relative;
top: 5px;
}
</style>
<p>Test passes if blue outline touches top left of green outline.</p>
<div id="container"><span id="target">x</span></div>

View file

@ -0,0 +1,12 @@
This directory contains the CSS build system.
It is recommended that it is run with `../build-css-testsuites.sh`, as
this ensures all dependencies are installed. Note that it is not
required to build the testsuites to run tests; you can just run tests
as with any other web-platform-tests tests (see ../../docs/).
The build system is formed of build.py in this directory, the
w3ctestlib package in w3ctestlib/, and the apiclient package in
apiclient/apiclient/. Note that apiclient exists as a separate
upstream project at https://hg.csswg.org/dev/apiclient/, and that
ideally any changes here should make it upstream.

View file

@ -1,77 +0,0 @@
#!/usr/bin/python
# This file is licensed under CC Zero
import sys
import html5lib
import re
if len(sys.argv) != 3:
print """! html2xhtml requires two arguments: the filename to read, and the filename to write"""
exit()
#######################################################################
# Parse HTML and output XHTML
f = open(sys.argv[1])
p = html5lib.HTMLParser()
t = p.parse(f)
o = html5lib.serializer.serialize(t, format='xhtml')
f.close()
#######################################################################
# Clean up the mess left by html5lib
def firstMatch(m): # Python makes s/x(y+)?/z$1/ very difficult
if m.group(1):
return m.group(1)
return ''
# Missing XHTML artifacts
o = re.sub('<!DOCTYPE [^>]+>',
'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">',
o);
o = re.sub('<html( [^>]+)?>',
lambda m : '<html' + firstMatch(m) + ' xmlns="http://www.w3.org/1999/xhtml">',
o);
# Fix weird reordering
o = re.sub('<link href="(.*?)" (.*?) ?/>',
lambda m : '<link ' + m.group(2) + ' href="' + m.group(1) + '"/>',
o);
# Indentation
o = re.sub('<!DOCTYPE ([^>]+)><html',
lambda m : '<!DOCTYPE ' + firstMatch(m) + '>\n<html',
o);
o = re.sub('<html( [^>]+)?><',
lambda m : '<html' + firstMatch(m) + '>\n<',
o);
o = re.sub('<head( [^>]+)?><',
lambda m : '<head' + firstMatch(m) + '>\n<',
o);
o = re.sub('</head><',
'</head>\n<',
o);
o = re.sub('<body( [^>]+)?><',
lambda m : '<body' + firstMatch(m) + '>\n<',
o);
o = re.sub('</body><',
'</body>\n<',
o);
o = re.sub('</html>$',
'</html>\n',
o);
o = re.sub('\xa0',
'&nbsp;',
o); # make nbsp visible to people viewing source
#######################################################################
# Write to file
f = open(sys.argv[2], 'w')
f.write(o.encode('utf-8'))
f.close()

View file

@ -1,86 +0,0 @@
#!/usr/bin/perl
# Print all files by filename and highlight duplicates
# Prints in format specified as an argument on the command line:
# '-txt' -> tab-separated database
# '-pre' -> linkified tab-separated database using HTML and <pre>
# '-html' -> HTML with tables
use Template;
$top = $ARGV[-1] || '.';
@files = `find $top -type f ! -ipath '*.hg*' ! -ipath '*build-test*' ! -ipath '*selectors3*'`;
foreach (@files) {
chomp;
m!^(?:\./)?((?:[^/]+/)*)([^/]+?)(\.[a-z]+)?$!;
next if (m!/support/!);
next if (m!\.css$!);
next if (m!boland!);
unless (exists $pairs{$2}) {
$pairs{$2} = ["$1$2$3"];
}
else {
push @{$pairs{$2}}, "$1$2$3";
}
}
my $tt = Template->new({ INCLUDE_PATH => $libroot . '/templates' }) || die $tt->error(), "\n";
# default template
$tmpl = <<'EOM'
[%- FOREACH name = pairs.keys.sort %]
[%- FOREACH path = pairs.$name %]
[% name %] [% path %]
[%- END %][% END %]
EOM
;
# linkified version
if ($ARGV[0] eq '-pre') {
$tmpl = <<'EOM'
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
<title>CSS Tests by Filename</title>
<pre> <!-- tables are too slow -->
[%- FOREACH name = pairs.keys.sort %]
[%- FOREACH path = pairs.$name %]
[% name %] <a href="[% path %]">[% path %]</a>
[%- END %][% END %]
</pre>
EOM
}
# tables version
elsif ($ARGV[0] eq '-html') {
$tmpl = <<'EOM'
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html>
<title>CSS Tests by Filename</title>
<style type="text/css">
table { table-layout: fixed; }
.dup { background: yellow; }
th, td { text-align: left; }
</style>
<body>
<h1>CSS Tests by Filename</h1>
<table>
<thead>
<tr><th>Filename <th>Path</tr>
</thead>
[%- FOREACH pair = pairs.pairs %]
<tbody>
[%- first = 1 %]
[%- FOREACH path = pair.value %]
<tr[%' class="support"' IF path.match('support') %]>
[%- IF first %]
<th rowspan="[% pair.value.size %]">[% pair.key %]
[%- END %]
<td><a href="[% path %]">[% path %]</a>
[%- first = 0 %]
[%- END %]
</tbody>
[%- END %]
</table>
EOM
}
$tt->process(\$tmpl, { 'pairs' => \%pairs });

View file

@ -1,8 +0,0 @@
#!/bin/bash
# First arg is directory path to list, second arg is path to output file (minus file extension)
find $1 -type f ! -ipath '*.hg*' ! -ipath '*build-test*' ! -ipath '*selectors3*' ! -ipath '*/support/*' ! -ipath '*boland*' ! -ipath '*incoming*' > $2.txt
perl -pi -e "s#^$1/?((?:[^/]+/)*)([^/]+?)(\.[a-z]+)?\$#\$2\t\$1\$2\$3#" $2.txt
sort $2.txt -o $2.txt
echo '<!DOCTYPE html><html><title>CSS Tests by Filename</title><pre>' > $2.html
perl -pe 's#\t(.+)$#\t<a href="$1">$1</a>#' < $2.txt >> $2.html
echo '</pre>' >> $2.html

View file

@ -1,66 +0,0 @@
#!/usr/bin/python
# HTMLMake
# Converts all files of specified extension from XHTML to HTML
# Written by fantasai
# Joint copyright 2010 W3C and Microsoft
# Licensed under BSD 3-Clause: <http://www.w3.org/Consortium/Legal/2008/03-bsd-license>
srcExt = '.xht'
dstExt = '.htm'
skipDirs = ('contributors/microsoft/submitted/support', # XXXfixme files should be .xht
'incoming', '.svn', 'CVS', '.hg')
import os.path
from os.path import join, getmtime
import sys
import re
import os
from w3ctestlib.Sources import XHTMLSource, SourceTree
def xhtml2html(source, dest):
"""Convert XHTML file given by path `source` into HTML file at path `dest`."""
# Parse and serialize
xs = XHTMLSource(SourceTree(None), source, dest)
o = xs.serializeHTML()
# Report errors
if xs.error:
print >>sys.stderr, "Error parsing XHTML file %s: %s" % (source, xs.error)
# Write
f = open(dest, 'w')
f.write(o.encode(xs.encoding, 'xmlcharrefreplace'))
f.close()
if len(sys.argv) == 3:
clobber = sys.argv[1] == '--clobber'
force = sys.argv[1] == '-f'
root = sys.argv[2]
elif len(sys.argv) == 2 and (sys.argv[1] != '--clobber' and sys.argv[1] != '-f'):
clobber = False;
force = False;
root = sys.argv[1]
else:
print "make-html converts all %s XHTML files to %s HTML files." % (srcExt, dstExt)
print "Only changed files are converted, unless you specify -f."
print "To use, specify the root directory of the files you want converted, e.g."
print " make-html ."
print "To delete all files with extension %s, specify the --clobber option." % dstExt
exit()
for root, dirs, files in os.walk(root):
for skip in skipDirs:
if skip in dirs:
dirs.remove(skip)
for file in files:
if clobber:
if file.endswith(dstExt):
os.remove(join(root, file))
elif file.endswith(srcExt):
source = join(root, file)
dest = join(root, file[0:-1*len(srcExt)] + dstExt)
if not os.path.exists(dest) or getmtime(source) > getmtime(dest) or force:
# print "Processing %s" % source
xhtml2html(source, dest)

View file

@ -1,156 +0,0 @@
#!/usr/bin/python
# This file is licensed under CC Zero
import os
from os.path import join
import shutil
import filecmp
# Files to not sync across support/ directories
fileExcludes = ('README')
dirExcludes = ('.svn', '.hg', 'CVS')
# To prevent support files from being propagated into a particular support/
# directory, add a file named LOCK
def propagate(source, dest, errors):
"""Compare each file and copy from source to destination.
Do nothing and flag an error if the destination already exists
but is different. Recurse.
source and dest are both directory paths.
errors is a list of 2-element tuples, the first being a
source filepath and the second a destination filepath,
of file pairs where the destination isdifferent from
"""
# This directory is locked; don't propagate
if os.path.exists(join(dest, 'LOCK')): return
# If the source directory doesn't exist return
if not os.path.exists(source): return
# Get the file and directory lists for source
children = os.listdir(source)
for name in children:
origin = join(source, name)
copy = join(dest, name)
if os.path.isfile(origin):
if name in fileExcludes: continue
# Copy over the file if it needs copying
if not os.path.exists(copy): # file missing
shutil.copy2(origin, copy) # copy it over
elif not filecmp.cmp(origin, copy): # files differ
if not filecmp.cmp(origin, copy, True): # contents equal, stats differ
shutil.copystat(origin, copy) # update stats so they match for next time
else: # contents differ
errors.append((origin, copy))
elif os.path.isdir(origin):
if name in dirExcludes: continue
# Duplicate the directory structure and propagate the subtree
if not os.path.exists(copy):
os.makedirs(copy)
propagate(origin, copy, errors)
if len(children) == 0:
print "Warn: " + source + " is empty.\n"
def waterfall(parentDir, childDir, errors):
"""Copy down support files from parent support to child.
parentDir is the parent of the parent support directory.
childDir is the parent of the current support directory,
that we should copy into.
waterfall recurses into childDir's children."""
assert os.path.exists(join(parentDir, 'support')), join(parentDir, 'support') + " doesn't exist\n"
if os.path.exists(join(childDir, 'support')):
propagate(join(parentDir, 'support'), join(childDir, 'support'), errors)
dirs = os.walk(childDir).next()[1]
for name in dirs:
if name == 'support':
pass
elif name not in dirExcludes:
waterfall(childDir, join(childDir, name), errors)
def outline(source, dest, errors):
"""Copy over directory structure and all files under any support/ directories
source and dest are both directory paths.
errors is a list of 2-element tuples, the first being a
source filepath and the second a destination filepath,
of support file pairs where the destination copy is
different from the source
"""
# Get the directory list for source
dirs = os.walk(source).next()[1]
# Copy directory structure
for name in dirs:
if name in dirExcludes: continue
origin = join(source, name)
copy = join(dest, name)
if not os.path.exists(copy):
os.mkdirs(copy)
if name == 'support':
# Copy support files
propagate(origin, copy, errors)
else:
outline(origin, copy, errors)
def syncSupport(source, dest, errors):
"""For each support directory in dest, propagate the corresponding support
files from source.
source and dest are both directory paths.
errors is a list of 2-element tuples, the first being a
source filepath and the second a destination filepath,
of support file pairs where the destination copy is
different from the source
"""
# Get the directory list for est
dirs = os.walk(dest).next()[1]
# Scan directory structure, building support dirs as necessary
for name in dirs:
if name in dirExcludes: continue
master = join(source, name)
slave = join(dest, name)
if name == 'support':
# Copy support files
propagate(master, slave, errors)
else:
syncSupport(master, slave, errors)
def main():
# Part I: Propagate support files through approved/
errors = []
root, dirs, _ = os.walk('.').next()
if 'approved' in dirs:
root = join(root, 'approved')
suites = os.walk(root).next()[1]
suites = filter(lambda name: name not in dirExcludes, suites)
for suite in suites:
waterfall(root, join(root, suite, 'src'), errors)
else:
print "Failed to find approved/ directory.\n"
exit();
# Part II: Propagate test suite support files into contributors/
if 'contributors' in dirs:
_, contribs, _ = os.walk('contributors').next()
for contributor in contribs:
contribRoot = join('contributors', contributor, 'submitted')
if not os.path.exists(contribRoot): continue # missing submitted folder
dirs = os.walk(contribRoot).next()[1]
for dir in dirs:
# Check if contributor has a top-level directory name matching
# one of our suites; if so, sync any matching support directories
if dir in suites:
suiteRoot = join(root, dir, 'src')
if os.path.exists(suiteRoot):
syncSupport(suiteRoot, join(contribRoot, dir), errors)
else:
print "Failed to find contributors/ directory.\n"
# Print all errors
for error in errors:
print "Mismatch: " + error[0] + " vs " + error [1] + " Copy failed.\n"
if __name__ == "__main__":
main()

View file

@ -1,18 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html>
<title>CSS Tests by Filename</title>
<body>
<h1>CSS Tests by Filename</h1>
<table>
<thead>
<tr><th>Filename <th>Path</tr>
</thead>
<tbody>
[% FOREACH pair = pairs.sort %][% parts = pair.split('\t') %]
<tr><th>[% parts.0 %] <td><a href="[% parts.1 %]">[% parts.1 %]</a>
[% END %]
</tbody>
</table>

View file

@ -1,12 +0,0 @@
Copyright (c) 2015, Mozilla
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View file

@ -1,223 +0,0 @@
import itertools
import os
import shutil
import subprocess
import sys
import vcs
here = os.path.abspath(os.path.dirname(__file__))
source_dir = os.path.join(here, "..", "..")
remote_built = "https://github.com/jgraham/css-test-built.git"
built_dir = os.path.join(here, "css-test-built")
local_files = ["manifest", "serve", "serve.py", ".gitmodules", "tools", "resources",
"config.default.json"]
def get_hgsubstate():
state = {}
with open(os.path.join(source_dir, ".hgsubstate"), "r") as f:
for line in f:
line = line.strip()
if not line:
continue
revision, path = line.split(" ", 1)
state[path] = revision
return state
def fetch_submodules():
hg = vcs.hg
orig_dir = os.getcwd()
state = get_hgsubstate()
for tool in ["apiclient", "w3ctestlib"]:
dest_dir = os.path.join(source_dir, "tools", tool)
repo_path = "tools/" + tool
if os.path.exists(os.path.join(dest_dir, ".hg")):
try:
os.chdir(dest_dir)
if repo_path in state:
rev = state[repo_path]
try:
hg("update", rev, log_error=False)
except subprocess.CalledProcessError:
hg("pull")
hg("update", rev)
else:
hg("pull")
hg("update")
finally:
os.chdir(orig_dir)
else:
hg("clone", ("https://hg.csswg.org/dev/%s" % tool), dest_dir)
try:
os.chdir(dest_dir)
if repo_path in state:
hg("update", state[repo_path])
else:
hg("update")
finally:
os.chdir(orig_dir)
def update_dist():
if not os.path.exists(built_dir) or not vcs.is_git_root(built_dir):
git = vcs.git
git("clone", "--depth", "1", remote_built, built_dir)
else:
git = vcs.bind_to_repo(vcs.git, built_dir)
git("fetch")
if "origin/master" in git("branch", "-a"):
git("checkout", "master")
git("merge", "--ff-only", "origin/master")
git = vcs.bind_to_repo(vcs.git, built_dir)
git("config", "user.email", "CssBuildBot@users.noreply.github.com")
git("config", "user.name", "CSS Build Bot")
git("submodule", "update", "--init", "--recursive")
def setup_virtualenv():
virtualenv_path = os.path.join(here, "_virtualenv")
if not os.path.exists(virtualenv_path):
subprocess.check_call(["virtualenv", virtualenv_path])
activate_path = os.path.join(virtualenv_path, "bin", "activate_this.py")
execfile(activate_path, dict(__file__=activate_path))
subprocess.check_call(["pip", "-q", "install", "mercurial"])
subprocess.check_call(["pip", "-q", "install", "html5lib==0.9999999"])
subprocess.check_call(["pip", "-q", "install", "lxml"])
subprocess.check_call(["pip", "-q", "install", "Template-Python"])
def update_to_changeset(changeset):
git = vcs.bind_to_repo(vcs.git, source_dir)
git("checkout", changeset)
apply_build_system_fixes()
def apply_build_system_fixes():
fixes = [
"c017547f65e07bdd889736524d47824d032ba2e8",
"cb4a737a88aa7e2f4e54383c57ffa2dfae093dcf",
"ec540343a3e729644c8178dbcf6d063dca20d49f",
]
git = vcs.bind_to_repo(vcs.git, source_dir)
for fix in fixes:
git("cherry-pick", "--keep-redundant-commits", fix)
def build_tests():
subprocess.check_call(["python", os.path.join(source_dir, "tools", "build.py")],
cwd=source_dir)
def remove_current_files():
for node in os.listdir(built_dir):
if node.startswith(".git"):
continue
if node in ("resources", "tools"):
continue
path = os.path.join(built_dir, node)
if os.path.isdir(path):
shutil.rmtree(path)
else:
os.remove(path)
def copy_files():
dist_path = os.path.join(source_dir, "dist")
for node in os.listdir(dist_path):
src_path = os.path.join(dist_path, node)
dest_path = os.path.join(built_dir, node)
if os.path.isdir(src_path):
shutil.copytree(src_path, dest_path)
else:
shutil.copy2(src_path, dest_path)
def update_git():
git = vcs.bind_to_repo(vcs.git, built_dir)
git("add", ".")
def add_changeset(changeset):
git = vcs.bind_to_repo(vcs.git, built_dir)
dest_path = os.path.join(built_dir, "source_rev")
with open(dest_path, "w") as f:
f.write(changeset)
git("add", os.path.relpath(dest_path, built_dir))
def commit(changeset):
git = vcs.git
msg = git("log", "-r", changeset, "-n", "1", "--pretty=%B", repo=source_dir)
msg = "%s\n\nBuild from revision %s" % (msg, changeset)
git("commit", "-m", msg, repo=built_dir)
def get_new_commits():
git = vcs.bind_to_repo(vcs.git, source_dir)
commit_path = os.path.join(built_dir, "source_rev")
with open(commit_path) as f:
prev_commit = f.read().strip()
if git("rev-parse", "--revs-only", prev_commit).strip() != prev_commit:
# we don't have prev_commit in current tree, so let's just do what's new
commit_range = os.environ['TRAVIS_COMMIT_RANGE']
assert (os.environ["TRAVIS_PULL_REQUEST"] != "false" or
os.environ["TRAVIS_BRANCH"] != "master")
else:
merge_base = git("merge-base", prev_commit, os.environ['TRAVIS_COMMIT']).strip()
commit_range = "%s..%s" % (merge_base, os.environ['TRAVIS_COMMIT'])
commits = git("log", "--pretty=%H", "-r", commit_range).strip()
if not commits:
return []
return reversed(commits.split("\n"))
def maybe_push():
if os.environ["TRAVIS_PULL_REQUEST"] != "false":
return
if os.environ["TRAVIS_BRANCH"] != "master":
return
git = vcs.bind_to_repo(vcs.git, built_dir)
out = "https://%s@github.com/jgraham/css-test-built.git" % os.environ["TOKEN"]
git("remote", "add", "out", out, quiet=True)
for i in range(2):
try:
git("push", "out", "HEAD:master")
except subprocess.CalledProcessError:
if i == 0:
git("fetch", "origin")
git("rebase", "origin/master")
else:
return
raise Exception("Push failed")
def main():
setup_virtualenv()
fetch_submodules()
update_dist()
changesets = list(get_new_commits())
print >> sys.stderr, "Building %d changesets:" % len(changesets)
print >> sys.stderr, "\n".join(changesets)
if len(changesets) > 50:
raise Exception("Building more than 50 changesets, giving up")
for changeset in changesets:
update_to_changeset(changeset)
remove_current_files()
build_tests()
copy_files()
update_git()
add_changeset(changeset)
commit(changeset)
maybe_push()
if __name__ == "__main__":
main()

View file

@ -1,43 +0,0 @@
import subprocess
import sys
from functools import partial
def vcs(bin_name):
def inner(command, *args, **kwargs):
repo = kwargs.pop("repo", None)
log_error = kwargs.pop("log_error", True)
quiet = kwargs.pop("quiet", False)
if kwargs:
raise TypeError, kwargs
args = list(args)
proc_kwargs = {}
if repo is not None:
proc_kwargs["cwd"] = repo
command_line = [bin_name, command] + args
if not quiet:
print >> sys.stderr, " ".join(command_line[:10])
try:
return subprocess.check_output(command_line, stderr=subprocess.STDOUT, **proc_kwargs)
except subprocess.CalledProcessError as e:
if log_error:
print >> sys.stderr, e.output
raise
return inner
git = vcs("git")
hg = vcs("hg")
def bind_to_repo(vcs_func, repo):
return partial(vcs_func, repo=repo)
def is_git_root(path):
try:
rv = git("rev-parse", "--show-cdup", repo=path)
except subprocess.CalledProcessError:
return False
return rv == "\n"

View file

@ -40,7 +40,12 @@
cover all of [% suites.$suite.spec %]. Your help is welcome in this effort.
[% END %]
The appropriate mailing list for submitting tests and bug reports is
<a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>.
<a href="http://lists.w3.org/Archives/Public/public-css-testsuite/">public-css-testsuite@w3.org</a>.</p>
<p>
To report bugs or feedback about a specific test file,
search for the filename (without extension) in
<a href="https://github.com/w3c/web-platform-tests/issues">Web Platform Tests Issues</a>,
and file a new issue if necessary with suggested label "wg-css".
More information on the contribution process and test guidelines is
available on the <a href="http://wiki.csswg.org/test">wiki
page</a>.</p>
@ -187,4 +192,4 @@
[% IF suite == 'css2.1' %]
<p>...and all the <a href="http://www.w3.org/Style/CSS/Test/CSS1/current/tsack.html">contributors
to the CSS1 test suite</a>.</p>
[% END %]
[% END %]

View file

@ -0,0 +1,42 @@
<!DOCTYPE html>
<style>
body, div, html {
height: 100%;
width: 100%;
overflow: hidden;
}
p {
margin-bottom: 1000px;
margin-right: 1000px;
}
</style>
<body>
<div id="blocker">
<p>This page blocks 'touchstart' and 'touchmove'.</p>
</div>
<script>
function doSomethingUnimportant(e) {
return false !== e;
}
function preventDefault(e) {
e.preventDefault();
}
document.addEventListener("touchstart", doSomethingUnimportant, {passive: false});
document.addEventListener("touchmove", doSomethingUnimportant, {passive: false});
function messageHandler(e) {
let msg = e.data;
let element = document.querySelector(msg.query);
if (msg.prevent) {
element.addEventListener(msg.event_type, preventDefault, {passive: false});
} else {
element.addEventListener(msg.event_type, doSomethingUnimportant);
}
e.source.postMessage(msg, "*");
}
window.addEventListener("message", messageHandler);
</script>
</body>

View file

@ -0,0 +1,237 @@
<!doctype html>
<title>vertical-scroll test for touch-action</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/feature-policy/experimental-features/resources/common.js"></script>
<script src="/feature-policy/experimental-features/resources/vertical-scroll.js"></script>
<style>
html, body {
height: 100%;
width: 100%;
}
iframe {
width: 90%;
height: 90%;
margin: 0;
padding: 0;
}
.spacer {
width: 100%;
height: 100%;
margin: 100%;
}
</style>
<iframe></iframe>
<br/>
<p>Spacers below to make page scrollable</p>
<br/>
<div class="spacer"></div>
<div class="spacer"></div>
<p> EOF </p>
<script>
"use strict";
let url = url_base + "vertical-scroll-touch-block.html";
let iframeElement = document.querySelector("iframe");
// Wait for the helper scripts to load.
promise_test(async() => {
if (window.touch_scroll_api_ready)
return Promise.resolve();
await new Promise( (r) => {
window.resolve_on_touch_scroll_api_ready = r;
});
}, "Make sure input injection API is ready.");
// Sanity-check: Verify we can scroll using the test-API. The <iframe> with no
// query arguments would not preventDefault() any events.
promise_test(async() => {
window.scrollTo(0, 0);
await loadUrlInIframe(iframeElement, url);
await inject_scroll("down");
assert_greater_than(window.scrollY, 0, "Page must have scrolled down.");
await inject_scroll("right");
assert_greater_than(window.scrollX, 0, "Page must have scrolled right.");
}, "Verify that the page normally scrolls.");
// Enable 'vertical-scroll': Blocking "touchstart" can block scrolling.
promise_test(async() => {
window.scrollTo(0, 0);
setFeatureState(iframeElement, "vertical-scroll", "*");
await loadUrlInIframe(iframeElement, url);
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchstart",
query: "#blocker",
prevent: true
});
await inject_scroll("down");
assert_equals(window.scrollY,
0,
"Main frame must not scroll vertically.");
}, "Calling 'preventDefault' on 'touchstart' blocks vertical scroll when " +
" the feature is enabled.");
// Disable 'vertical-scroll': Blocking "touchstart" cannot block vertical
// scroll.
promise_test(async() => {
window.scrollTo(0, 0);
setFeatureState(iframeElement, "vertical-scroll", "'none'");
await loadUrlInIframe(iframeElement, url);
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchstart",
query: "#blocker",
prevent: true
});
await inject_scroll("down");
assert_greater_than(window.scrollY,
0,
"Main frame must scroll vertically.");
// Horizontal scrolling must still be blocked.
window.scrollTo(0, 0);
await inject_scroll("right");
assert_equals(window.scrollX,
0,
"Main frame must not scroll horizontally.");
}, "When feature is disabled, calling 'preventDefault' on 'touchstart' does" +
" not block vertical scroll, but still bocks horizontal scroll.");
// Enable 'vertical-scroll': Blocking "touchmove" can block scrolling.
promise_test(async() => {
// Make sure <window> can scroll both towards right and bottom.
window.scrollTo(0, 0);
setFeatureState(iframeElement, "vertical-scroll", "*");
await loadUrlInIframe(iframeElement, url);
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchmove",
query: "#blocker",
prevent: true
});
await inject_scroll("down");
assert_equals(window.scrollY,
0,
"Main frame must not scroll vertically");
}, "Calling 'preventDefault' on 'touchmove' blocks vertical scroll when " +
"the feature is enabled.");
// Disable 'vertical-scroll': Blocking "touchmove" cannot block vertical
// scroll.
promise_test(async() => {
window.scrollTo(0, 0);
setFeatureState(iframeElement, "vertical-scroll", "'none'");
await loadUrlInIframe(iframeElement, url);
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchmove",
query: "#blocker",
prevent: true
});
await new Promise((r) => {
window.setTimeout(r, 100);
});
await inject_scroll("down");
assert_greater_than(window.scrollY,
0,
"Main frame must scroll vertically.");
}, "When feature is disabled, calling 'preventDefault' on 'touchmove' does" +
" not block vertical scroll.");
// Disable 'vertical-scroll': Add a non-preventing handler, and then a
// preventing handler and verify vertical scroll is possible and horizontal
// is blocked.
promise_test(async() => {
setFeatureState(iframeElement, "vertical-scroll", "'none'");
await loadUrlInIframe(iframeElement, url);
// Add a non-blocking handler.
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchstart",
query: "#blocker",
prevent: false
});
window.scrollTo(0, 0);
await inject_scroll("down");
assert_greater_than(window.scrollY, 0, "Page must have scrolled down.");
window.scrollTo(0, 0);
await inject_scroll("right");
assert_greater_than(window.scrollX, 0, "Page must have scrolled right.");
// Add a blocking handler.
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchstart",
query: "#blocker",
prevent: true
});
window.scrollTo(0, 0);
await inject_scroll("down");
assert_greater_than(window.scrollY,
0,
"Page must have scrolled down (preventing handler).");
window.scrollTo(0, 0);
await inject_scroll("right");
assert_equals(window.scrollX,
0,
"Page must not have scrolled horizontally.");
}, "Verify that starting with a non-preventing listener and then switching" +
" to a preventing one works as intended.");
// Disable 'vertical-scroll': A preventing 'touchstart' handler does not allow
// other multi-touch actions such as 'pinch-zoom'.
promise_test(async() => {
assert_true(!!window.visualViewport,
"'visualViewport' is needed for this test.");
setFeatureState(iframeElement, "vertical-scroll", "'none'");
await loadUrlInIframe(iframeElement, url);
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchstart",
query: "#blocker",
prevent: false
});
// Sanity check: Pinch zoom in should work since 'touchstart' is not
// preventing.
let current_scale_factor = window.visualViewport.scale;
await inject_zoom("in");
let new_scale_factor = window.visualViewport.scale;
assert_greater_than(
new_scale_factor,
current_scale_factor,
"Pinch zoom should work since 'touchstart' is not prevented.");
// Add a preventing handler and verify pinch zoom is now blocked.
await sendMessageAndGetResponse(iframeElement.contentWindow,
{
event_type: "touchstart",
query: "#blocker",
prevent: true
});
current_scale_factor = new_scale_factor;
await inject_zoom("out");
new_scale_factor = window.visualViewport.scale;
assert_equals(
new_scale_factor,
current_scale_factor,
"Pinch zoom must be blocked.")
}, "Verify that pinch zoom is blocked in frames with 'vertical-scroll' none'" +
" where 'touchstart' is prevent defaulted.");
</script>

View file

@ -18,7 +18,7 @@ async_test(t => {
const secondPromise = document.exitFullscreen();
assert_equals(document.fullscreenElement, div, "fullscreenElement after second exitFullscreen()");
document.onfullscreenchange = t.step_func(() => {
document.onfullscreenchange = t.step_func(event => {
assert_equals(document.fullscreenElement, null);
// Ensure that there's only one fullscreenchange event.
document.onfullscreenchange = t.unreached_func("second fullscreenchange event");

View file

@ -7,12 +7,23 @@
async_test(function(t)
{
var sync = true;
var promise_executed = false;
assert_equals(document.onfullscreenerror, null, "initial onfullscreenerror");
document.onfullscreenerror = t.step_func_done(function(event) {
assert_true(promise_executed);
assert_false(sync);
});
var e = document.createElement('span');
e.requestFullscreen();
var promise = e.requestFullscreen();
if (promise) {
promise.catch(()=> {
assert_false(sync);
promise_executed = true;
});
} else {
// If promises aren't supported just treat it as already done.
promise_executed = true;
}
sync = false;
});
</script>

View file

@ -6,14 +6,24 @@
<script>
async_test(t => {
const div = document.querySelector("div");
var promise_executed = false;
document.addEventListener("fullscreenerror", t.step_func_done(event => {
assert_equals(event.target, div, "event.target");
assert_true(event.bubbles, "event.bubbles");
assert_false(event.cancelable, "event.cancelable");
assert_true(event.composed, "event.composed");
assert_true(promise_executed, "promise executed");
}));
div.requestFullscreen();
var promise = div.requestFullscreen();
if (promise) {
promise.catch(()=> {
promise_executed = true;
});
} else {
// If promises aren't supported just treat it as already done.
promise_executed = true;
}
});
</script>

View file

@ -28,11 +28,19 @@ async_test(t => {
}, 'Timing of fullscreenchange and resize events');
async_test(t => {
document.createElement('a').requestFullscreen();
var promise = document.createElement('a').requestFullscreen();
var promise_executed = false;
if (promise) {
promise.catch(()=>{promise_executed = true; });
} else {
// if promises aren't supported treat it as executed.
promise_executed = true;
}
// If fullscreenerror is an animation frame event, then animation frame
// callbacks should be run after it is fired, before the timer callback.
document.onfullscreenerror = t.step_func(() => {
assert_true(promise_executed, "promise executed");
step_timeout(t.unreached_func('timer callback'));
requestAnimationFrame(t.step_func_done());
});

View file

@ -0,0 +1,17 @@
<!DOCTYPE html>
<title>Promises#reject</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
async_test(function(t)
{
var e = document.createElement('span');
e.requestFullscreen().catch(t.step_func_done());
});
async_test(function(t)
{
var e = document.createElement('span');
document.exitFullscreen().catch(t.step_func_done());
});
</script>

View file

@ -0,0 +1,21 @@
<!DOCTYPE html>
<title>Promises#resolve</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="../trusted-click.js"></script>
<div id="log"></div>
<script>
async_test(function(t)
{
var div = document.querySelector("div");
trusted_request_with_promise(t, div, document.body,
() => {
assert_equals(document.fullscreenElement, div, "fullscreenElement before exitFullscreen()");
document.exitFullscreen().then(()=> {
assert_equals(document.fullscreenElement, null, "fullscreenElement after exiting fullscreen");
t.done();
});
assert_equals(document.fullscreenElement, div, "fullscreenElement after exitFullscreen()");
}, t.unreached_func("Request fullscreen failed"));
});
</script>

View file

@ -7,6 +7,7 @@
<iframe></iframe>
<script>
async_test(t => {
t.add_cleanup(() => document.exitFullscreen());
const div = document.querySelector("div");
const iframe = document.querySelector("iframe");
document.onfullscreenchange = t.step_func(event => {
@ -16,6 +17,9 @@ async_test(t => {
assert_equals(div.ownerDocument, document);
iframe.contentDocument.body.appendChild(div);
assert_not_equals(div.ownerDocument, document);
// Moving /div/ removes it from the top layer and thus the fullscreen
// element synchronously becomes null.
assert_equals(document.fullscreenElement, null);
div.onfullscreenchange = t.unreached_func("fullscreenchange fired on element");
iframe.contentDocument.onfullscreenchange = t.unreached_func("fullscreenchange fired on other document");

View file

@ -6,6 +6,7 @@
<div></div>
<script>
async_test(t => {
t.add_cleanup(() => document.exitFullscreen());
const div = document.querySelector("div");
document.onfullscreenchange = t.step_func(event => {
const inactiveDocument = document.implementation.createDocument(null, "");

View file

@ -10,12 +10,15 @@
<script>
async_test(function(t)
{
t.add_cleanup(() => document.exitFullscreen());
var parent = document.getElementById("parent");
trusted_request(t, parent);
document.onfullscreenchange = t.step_func(function()
{
assert_equals(document.fullscreenElement, parent);
parent.textContent = ""; // removes all children
// The fullscreen element should not be affected.
assert_equals(document.fullscreenElement, parent);
document.onfullscreenchange = t.unreached_func("fullscreenchange event");
// A fullscreenchange event would be fired after an async section
// and an animation frame task, so wait until after that.

View file

@ -10,6 +10,7 @@
<script>
async_test(function(t)
{
t.add_cleanup(() => document.exitFullscreen());
var first = document.getElementById("first");
trusted_request(t, first);
document.onfullscreenchange = t.step_func(function(event)
@ -23,6 +24,9 @@ async_test(function(t)
assert_equals(document.fullscreenElement, last);
assert_equals(event.target, last);
first.remove();
// Both /first/ and /last/ were removed from the top layer and
// thus the fullscreen element synchronously becomes null.
assert_equals(document.fullscreenElement, null);
document.onfullscreenchange = t.step_func_done(function(event)
{
assert_equals(document.fullscreenElement, null);

View file

@ -10,6 +10,7 @@
<script>
async_test(function(t)
{
t.add_cleanup(() => document.exitFullscreen());
var first = document.getElementById("first");
trusted_request(t, first);
document.onfullscreenchange = t.step_func(function(event)
@ -23,9 +24,14 @@ async_test(function(t)
assert_equals(document.fullscreenElement, last);
assert_equals(event.target, last);
last.remove();
// Because /last/ was removed from the top layer, we exit
// fullscreen element synchronously.
assert_equals(document.fullscreenElement, first);
document.onfullscreenchange = t.step_func_done(function(event)
{
assert_equals(document.fullscreenElement, first);
// fullscreen change element should be queued against the
// document target.
assert_equals(document.fullscreenElement, null);
assert_equals(event.target, document);
});
});

View file

@ -10,6 +10,7 @@
<script>
async_test(function(t)
{
t.add_cleanup(() => document.exitFullscreen());
var child = document.getElementById("child");
trusted_request(t, child);
document.onfullscreenchange = t.step_func(function(event)
@ -17,6 +18,9 @@ async_test(function(t)
assert_equals(document.fullscreenElement, child);
assert_equals(event.target, child);
child.parentNode.remove();
// Because /child/ was removed from the top layer, the fullscreen
// element becomes null synchronously.
assert_equals(document.fullscreenElement, null);
document.onfullscreenchange = t.step_func_done(function(event)
{
assert_equals(document.fullscreenElement, null);

View file

@ -8,12 +8,16 @@
<script>
async_test(function(t)
{
t.add_cleanup(() => document.exitFullscreen());
var single = document.getElementById("single");
document.onfullscreenchange = t.step_func(function(event)
{
assert_equals(document.fullscreenElement, single);
assert_equals(event.target, single);
single.remove();
// Because /single/ was removed from the top layer, the fullscreen
// element becomes null synchronously.
assert_equals(document.fullscreenElement, null);
document.onfullscreenchange = t.step_func_done(function(event)
{
assert_equals(document.fullscreenElement, null);

View file

@ -19,5 +19,20 @@ function trusted_click(test, callback, container)
// Invokes element.requestFullscreen() from a trusted click.
function trusted_request(test, element, container)
{
trusted_click(test, () => element.requestFullscreen(), container || element.parentNode);
trusted_click(test, () => {
var promise = element.requestFullscreen();
if (promise) {
// Keep the promise resolution silent. Otherwise unhandledrejection
// may fire for the failure test cases.
promise.then(() => {}, () => {});
}
}, container || element.parentNode);
}
// Invokes element.requestFullscreen() from a trusted click.
function trusted_request_with_promise(test, element, container, resolve, reject)
{
trusted_click(test, () => {
element.requestFullscreen().then(resolve, reject);
}, container || element.parentNode);
}

View file

@ -0,0 +1,35 @@
<!DOCTYPE html>
<title>UA style for form in table elements</title>
<link rel="help" href="https://html.spec.whatwg.org/multipage/rendering.html#tables-2">
<link rel="author" title="Rune Lillesveen" href="mailto:futhark@chromium.org">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<style>
.block { display: block !important }
</style>
<div id="display">
<table><form></form></table>
<table><thead><form></form></thead></table>
<table><tbody><form></form></tbody></table>
<table><tfoot><form></form></tfoot></table>
<table><tr><form></form></tr></table>
</div>
<div id="important">
<table><form class="block"></form></table>
<table><thead><form class="block"></form></thead></table>
<table><tbody><form class="block"></form></tbody></table>
<table><tfoot><form class="block"></form></tfoot></table>
<table><tr><form class="block"></form></tr></table>
</div>
<script>
for (const form of display.querySelectorAll("form")) {
test(function() {
assert_equals(getComputedStyle(form).display, "none");
}, `Computed display of form inside ${form.parentNode.nodeName} should be 'none'`);
}
for (const form of important.querySelectorAll("form")) {
test(function() {
assert_equals(getComputedStyle(form).display, "none");
}, `Computed display of form inside ${form.parentNode.nodeName} should be 'none' (!important UA style))`);
}
</script>

View file

@ -0,0 +1,23 @@
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>UA style for form in table elements - XHTML</title>
<link rel="help" href="https://html.spec.whatwg.org/multipage/rendering.html#tables-2" />
<link rel="author" title="Rune Lillesveen" href="mailto:futhark@chromium.org" />
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
</head>
<body>
<table><form></form></table>
<table><thead><form></form></thead></table>
<table><tbody><form></form></tbody></table>
<table><tfoot><form></form></tfoot></table>
<table><tr><form></form></tr></table>
<script>
for (const form of document.querySelectorAll("form")) {
test(function() {
assert_equals(getComputedStyle(form).display, "block");
}, `Computed display of form inside ${form.parentNode.nodeName} in xhtml should be 'block'`);
}
</script>
</body>
</html>

View file

@ -0,0 +1,24 @@
<!doctype html>
<title>dialog element: removing from document after showModal()</title>
<link rel=help href="https://html.spec.whatwg.org/multipage/interactive-elements.html#dom-dialog-showmodal">
<link rel=help href="https://fullscreen.spec.whatwg.org/#removing-steps">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<dialog></dialog>
<script>
async_test(t => {
const dialog = document.querySelector('dialog')
dialog.showModal()
assert_true(dialog.open)
// The dialog element is now in top layer. Removing it should synchronously
// remove it from top layer, but should leave it in a strange limbo state.
dialog.addEventListener('close', t.unreached_func('close event'))
dialog.remove()
assert_true(dialog.open)
// if an event was queued, it would fire before this timeout
step_timeout(t.step_func_done(() => {
assert_true(dialog.open)
// pass if no close event was fired
}))
})
</script>

View file

@ -4,35 +4,26 @@
<script src="/resources/testharnessreport.js"></script>
<script src="/resources/WebIDLParser.js"></script>
<script src="/resources/idlharness.js"></script>
<pre id="untested_idl">
interface InputEvent {
};
</pre>
<pre id='idl'>
partial interface InputEvent {
readonly attribute DOMString inputType;
readonly attribute DataTransfer? dataTransfer;
sequence<StaticRange> getTargetRanges();
};
partial dictionary InputEventInit {
DOMString inputType = "";
DataTransfer? dataTransfer = null;
sequence<StaticRange> targetRanges = [];
};
</pre>
<script>
(function(){
"use strict";
"use strict";
function doTest([input_events]) {
const idl_array = new IdlArray();
idl_array.add_untested_idls(document.getElementById("untested_idl").textContent);
idl_array.add_idls(document.getElementById("idl").textContent);
idl_array.add_untested_idls('interface InputEvent {};');
idl_array.add_untested_idls('dictionary InputEventInit {};');
idl_array.add_idls(input_events);
idl_array.add_objects({
InputEvent: ['new InputEvent("foo")'],
InputEvent: ['new InputEvent("foo")'],
});
idl_array.test();
})();
}
function fetchText(url) {
return fetch(url).then((response) => response.text());
}
promise_test(() => {
return Promise.all(["/interfaces/input-events.idl"].map(fetchText))
.then(doTest);
}, "Test IDL implementation of Input Events");
</script>

View file

@ -0,0 +1,11 @@
partial interface InputEvent {
readonly attribute DOMString inputType;
readonly attribute DataTransfer? dataTransfer;
sequence<StaticRange> getTargetRanges();
};
partial dictionary InputEventInit {
DOMString inputType = "";
DataTransfer? dataTransfer = null;
sequence<StaticRange> targetRanges = [];
};

View file

@ -0,0 +1,78 @@
dictionary MediaConfiguration {
VideoConfiguration video;
AudioConfiguration audio;
};
dictionary MediaDecodingConfiguration : MediaConfiguration {
required MediaDecodingType type;
};
dictionary MediaEncodingConfiguration : MediaConfiguration {
required MediaEncodingType type;
};
enum MediaDecodingType {
"file",
"media-source",
};
enum MediaEncodingType {
"record",
"transmission"
};
dictionary VideoConfiguration {
required DOMString contentType;
required unsigned long width;
required unsigned long height;
required unsigned long long bitrate;
required DOMString framerate;
};
dictionary AudioConfiguration {
required DOMString contentType;
DOMString channels;
unsigned long long bitrate;
unsigned long samplerate;
};
interface MediaCapabilitiesInfo {
readonly attribute boolean supported;
readonly attribute boolean smooth;
readonly attribute boolean powerEfficient;
};
[Exposed=(Window)]
partial interface Navigator {
[SameObject] readonly attribute MediaCapabilities mediaCapabilities;
};
[Exposed=(Worker)]
partial interface WorkerNavigator {
[SameObject] readonly attribute MediaCapabilities mediaCapabilities;
};
[Exposed=(Window, Worker)]
interface MediaCapabilities {
Promise<MediaCapabilitiesInfo> decodingInfo(MediaDecodingConfiguration configuration);
Promise<MediaCapabilitiesInfo> encodingInfo(MediaEncodingConfiguration configuration);
};
interface ScreenLuminance {
readonly attribute double min;
readonly attribute double max;
readonly attribute double maxAverage;
};
enum ScreenColorGamut {
"srgb",
"p3",
"rec2020",
};
partial interface Screen {
readonly attribute ScreenColorGamut colorGamut;
readonly attribute ScreenLuminance? luminance;
attribute EventHandler onchange;
};

View file

@ -0,0 +1,49 @@
[Exposed=Window]
partial interface Navigator {
[SameObject] readonly attribute MediaSession mediaSession;
};
enum MediaSessionPlaybackState {
"none",
"paused",
"playing"
};
enum MediaSessionAction {
"play",
"pause",
"seekbackward",
"seekforward",
"previoustrack",
"nexttrack",
};
callback MediaSessionActionHandler = void();
[Exposed=Window]
interface MediaSession {
attribute MediaMetadata? metadata;
attribute MediaSessionPlaybackState playbackState;
void setActionHandler(MediaSessionAction action, MediaSessionActionHandler? handler);
};
[Constructor(optional MediaMetadataInit init), Exposed=Window]
interface MediaMetadata {
attribute DOMString title;
attribute DOMString artist;
attribute DOMString album;
attribute FrozenArray<MediaImage> artwork;
};
dictionary MediaMetadataInit {
DOMString title = "";
DOMString artist = "";
DOMString album = "";
sequence<MediaImage> artwork = [];
};
dictionary MediaImage {
required USVString src;
DOMString sizes = "";
DOMString type = "";
};

View file

@ -1,24 +0,0 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the Static Range spec.
// See https://w3c.github.io/staticrange/
dictionary StaticRangeInit {
required Node startContainer;
required unsigned long startOffset;
required Node endContainer;
required unsigned long endOffset;
};
[Constructor(StaticRangeInit initDict),
Exposed=Window]
interface StaticRange {
attribute Node startContainer;
attribute unsigned long startOffset;
attribute Node endContainer;
attribute unsigned long endOffset;
readonly attribute boolean collapsed;
[NewObject] Range toRange();
};

View file

@ -11,81 +11,26 @@
</head>
<body>
<h1>Media Session IDL tests</h1>
<pre id='untested_idl' style='display:none'>
[Global=Window, Exposed=Window]
interface Window {
};
interface Worker {
};
interface Navigator {
};
interface WorkerNavigator {
};
</pre>
<pre id='idl'>
dictionary MediaConfiguration {
VideoConfiguration video;
AudioConfiguration audio;
};
dictionary MediaDecodingConfiguration : MediaConfiguration {
required MediaDecodingType type;
};
dictionary MediaEncodingConfiguration : MediaConfiguration {
required MediaEncodingType type;
};
enum MediaDecodingType {
"file",
"media-source",
};
dictionary VideoConfiguration {
required DOMString contentType;
required unsigned long width;
required unsigned long height;
required unsigned long bitrate;
required double framerate;
};
dictionary AudioConfiguration {
required DOMString contentType;
DOMString channels;
unsigned long bitrate;
unsigned long samplerate;
};
interface MediaCapabilitiesInfo {
readonly attribute boolean supported;
readonly attribute boolean smooth;
readonly attribute boolean powerEfficient;
};
[Exposed=(Window)]
partial interface Navigator {
[SameObject] readonly attribute MediaCapabilities mediaCapabilities;
};
[Exposed=(Worker)]
partial interface WorkerNavigator {
[SameObject] readonly attribute MediaCapabilities mediaCapabilities;
};
[Exposed=(Window, Worker)]
interface MediaCapabilities {
Promise<MediaCapabilitiesInfo> decodingInfo(MediaDecodingConfiguration configuration);
Promise<MediaCapabilitiesInfo> encodingInfo(MediaEncodingConfiguration configuration);
};
</pre>
<script>
var idl_array = new IdlArray();
idl_array.add_untested_idls(document.getElementById("untested_idl").textContent);
idl_array.add_idls(document.getElementById("idl").textContent);
idl_array.add_objects({
Navigator: ["navigator"]
});
idl_array.test();
"use strict";
function doTest([media_capabilities]) {
var idl_array = new IdlArray();
idl_array.add_untested_idls('interface Navigator {};');
idl_array.add_untested_idls('interface WorkerNavigator {};');
idl_array.add_untested_idls('interface Screen {};');
idl_array.add_idls(media_capabilities);
idl_array.add_objects({
Navigator: ["navigator"]
});
idl_array.test();
}
function fetchText(url) {
return fetch(url).then((response) => response.text());
}
promise_test(() => {
return Promise.all(["/interfaces/media-capabilities.idl"].map(fetchText))
.then(doTest);
}, "Test IDL implementation of Media Capabilities");
</script>
<div id="log"></div>
</body>

View file

@ -1 +1 @@
@miguelao
@yellowdoge

View file

@ -64,6 +64,34 @@ promise_test(t => {
}
}));
}, 'groupId is correctly supported by getUserMedia() for video devices');
promise_test(t => {
return navigator.mediaDevices.enumerateDevices()
.then(t.step_func(async devices => {
for (var i in devices) {
await navigator.mediaDevices.getUserMedia(
{audio: {groupId: {exact: devices[i].groupId}}})
.then(
t.step_func(stream => {
var found_device = devices.find(element => {
return element.deviceId ==
stream.getTracks()[0].getSettings().deviceId;
});
assert_true(undefined !== found_device);
assert_equals(found_device.kind, "audioinput");
assert_equals(found_device.groupId, devices[i].groupId);
}),
t.step_func(error => {
assert_equals(error.name, "OverconstrainedError");
assert_equals(error.constraint, "groupId");
var found_device = devices.find(element => {
return element.kind == "audioinput" &&
element.groupId == devices[i].groupId});
assert_true(undefined === found_device);
}));
}
}));
}, 'groupId is correctly supported by getUserMedia() for audio devices');
</script>
</body>
</html>

View file

@ -11,78 +11,28 @@
</head>
<body>
<h1>Media Session IDL tests</h1>
<pre id='untested_idl' style='display:none'>
[Global=Window, Exposed=Global]
interface Window {
};
interface Navigator {
};
</pre>
<pre id='idl'>
[Exposed=Window]
partial interface Navigator {
[SameObject] readonly attribute MediaSession mediaSession;
};
enum MediaSessionPlaybackState {
"none",
"paused",
"playing"
};
enum MediaSessionAction {
"play",
"pause",
"seekbackward",
"seekforward",
"previoustrack",
"nexttrack",
};
callback MediaSessionActionHandler = void();
[Exposed=Window]
interface MediaSession {
attribute MediaMetadata? metadata;
attribute MediaSessionPlaybackState playbackState;
void setActionHandler(MediaSessionAction action, MediaSessionActionHandler? handler);
};
[Constructor(optional MediaMetadataInit init), Exposed=Window]
interface MediaMetadata {
attribute DOMString title;
attribute DOMString artist;
attribute DOMString album;
attribute FrozenArray<MediaImage> artwork;
};
dictionary MediaMetadataInit {
DOMString title = "";
DOMString artist = "";
DOMString album = "";
sequence<MediaImage> artwork = [];
};
dictionary MediaImage {
required USVString src;
DOMString sizes = "";
DOMString type = "";
};
</pre>
<script>
var idl_array = new IdlArray();
idl_array.add_untested_idls(document.getElementById("untested_idl").textContent);
idl_array.add_idls(document.getElementById("idl").textContent);
idl_array.add_objects({
MediaMetadata: [new MediaMetadata()],
Navigator: ["navigator"]
});
idl_array.test();
"use strict";
function doTest([mediasession]) {
var idl_array = new IdlArray();
idl_array.add_untested_idls('interface Navigator {};');
idl_array.add_idls(mediasession);
idl_array.add_objects({
MediaMetadata: ["new MediaMetadata()"],
Navigator: ["navigator"]
});
idl_array.test();
}
function fetchText(url) {
return fetch(url).then((response) => response.text());
}
promise_test(() => {
return Promise.all(["/interfaces/mediasession.idl"].map(fetchText))
.then(doTest);
}, "Test IDL implementation of Media Session");
</script>
<div id="log"></div>
</body>

View file

@ -111,14 +111,14 @@ function perform_test() {
addEntryIfExists(entries, expected_entries, pathname + 'blue.png?id=object', 'object');
addEntryIfExists(entries, expected_entries, pathname + 'blue.png?id=video-poster', 'video');
addEntryIfExists(entries, expected_entries, '/media/test.mp4?id=video-src', 'video');
addEntryIfExists(entries, expected_entries, '/media/test.mp4?id=video-source', 'source');
addEntryIfExists(entries, expected_entries, '/media/test.ogv?id=video-source', 'source');
addEntryIfExists(entries, expected_entries, '/media/test.mp4?id=video-source', 'video');
addEntryIfExists(entries, expected_entries, '/media/test.ogv?id=video-source', 'video');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=video-track', 'track');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=audio-src', 'audio');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=audio-source-wav', 'source');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=audio-source-mpeg', 'source');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=audio-source-ogg', 'source');
addEntryIfExists(entries, expected_entries, pathname + 'blue.png?id=picture-source', 'source');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=audio-source-wav', 'audio');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=audio-source-mpeg', 'audio');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=audio-source-ogg', 'audio');
addEntryIfExists(entries, expected_entries, pathname + 'blue.png?id=picture-source', 'img');
addEntryIfExists(entries, expected_entries, pathname + 'blue.png?id=picture-img', 'img');
addEntryIfExists(entries, expected_entries, pathname + 'blue.png?id=picture-notsupported-img', 'img');
addEntryIfExists(entries, expected_entries, pathname + 'blue.png?id=picture-img-src', 'img');
@ -133,7 +133,7 @@ function perform_test() {
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=beacon', 'beacon');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?id=fetch', 'fetch');
addEntryIfExists(entries, expected_entries, pathname + 'empty.py?favicon', 'link');
addEntryIfExists(entries, expected_entries, pathname + 'eventsource.py?id=eventsource', 'eventsource');
addEntryIfExists(entries, expected_entries, pathname + 'eventsource.py?id=eventsource', 'other');
test_resource_entries(entries, expected_entries);
done();

View file

@ -258,11 +258,14 @@ IdlArray.prototype.add_dependency_idls = function(raw_idls, options)
});
this.partials.map(p => p.name).forEach(v => all_deps.add(v));
// Add the attribute idlTypes of all the nested members of all tested idls.
Object.values(this.members).filter(m => !m.untested && m.members).forEach(parsed => {
Object.values(parsed.members).filter(m => m.type === 'attribute').forEach(m => {
all_deps.add(m.idlType.idlType);
});
});
for (const obj of [this.members, this.partials]) {
const tested = Object.values(obj).filter(m => !m.untested && m.members);
for (const parsed of tested) {
for (const attr of Object.values(parsed.members).filter(m => !m.untested && m.type === 'attribute')) {
all_deps.add(attr.idlType.idlType);
}
}
}
if (options && options.except && options.only) {
throw new IdlHarnessError("The only and except options can't be used together.");

View file

@ -1,24 +0,0 @@
<!doctype html>
<title>StaticRange IDL tests</title>
<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";
promise_test(async () => {
const staticrange = await fetch("/interfaces/staticrange.idl").then(r => r.text());
const dom = await fetch("/interfaces/dom.idl").then(r => r.text());
const idl_array = new IdlArray();
idl_array.add_idls(staticrange);
idl_array.add_dependency_idls(dom);
idl_array.add_objects({
StaticRange: [
'new StaticRange({ start: document.body, end: document.body })'
],
});
idl_array.test();
}, "staticrange IDL");
</script>

View file

@ -11,6 +11,7 @@ onmessage = e => {
channel.port2.postMessage(e.data);
};
fetch_tests_from_worker(channel.port1);
channel.port1.start();
</script>
<iframe sandbox="allow-scripts" src="support/sandboxed-tests.html?pipe=sub"></iframe>
</body>