From a4eda174fac57b9c861c4cc2d6998ebb8a373eb2 Mon Sep 17 00:00:00 2001 From: WPT Sync Bot Date: Tue, 19 Jan 2021 08:19:35 +0000 Subject: [PATCH] Update web-platform-tests to revision 0f74915a040e481eefedaddd5fe0cf5c16043a5d --- .../FileAPI/url/url-charset.window.js.ini | 8 + .../CSS2/floats/hit-test-floats-004.html.ini | 4 + .../transform-scale-hittest.html.ini | 3 - .../cssom-view/elementFromPoint-001.html.ini | 4 - .../matchMedia-display-none-iframe.html.ini | 2 - .../fetch/content-type/response.window.js.ini | 16 +- .../fetch/content-type/script.window.js.ini | 3 + .../nosniff/parsing-nosniff.window.js.ini | 6 + ...ml.ini => traverse_the_history_4.html.ini} | 2 +- .../embedded-opener-remove-frame.html.ini | 1 - .../focus-management/focus-events.html.ini | 4 + .../supported-elements.html.ini | 3 +- .../iframe_sandbox_popups_escaping-1.html.ini | 2 +- ...rame_sandbox_popups_nonescaping-1.html.ini | 2 +- ...rame_sandbox_popups_nonescaping-2.html.ini | 1 + .../textfieldselection/select-event.html.ini | 70 +++--- ...le-event-handler-settings-objects.html.ini | 2 +- .../realtimeanalyser-fft-scaling.html.ini | 1 - .../sub-sample-buffer-stitching.html.ini | 3 + .../tests/element_click/events.py.ini | 4 + .../webmessaging/with-ports/017.html.ini | 5 - .../webmessaging/with-ports/018.html.ini | 5 + .../Worker/Worker-constructor.html.ini | 2 - .../FileAPI/url/url-charset.window.js.ini | 8 + tests/wpt/metadata/MANIFEST.json | 206 ++++++++++++++---- .../CSS2/floats/hit-test-floats-004.html.ini | 4 + .../transform-scale-hittest.html.ini | 3 - .../cssom-view/elementFromPoint-001.html.ini | 4 - .../matchMedia-display-none-iframe.html.ini | 2 - .../fetch/content-type/response.window.js.ini | 16 +- .../fetch/content-type/script.window.js.ini | 3 + .../nosniff/parsing-nosniff.window.js.ini | 6 + ...ml.ini => traverse_the_history_4.html.ini} | 2 +- .../embedded-opener-remove-frame.html.ini | 1 - .../focus-management/focus-events.html.ini | 4 + .../supported-elements.html.ini | 3 +- .../iframe_sandbox_popups_escaping-1.html.ini | 2 +- ...rame_sandbox_popups_nonescaping-1.html.ini | 2 +- ...rame_sandbox_popups_nonescaping-2.html.ini | 1 + .../textfieldselection/select-event.html.ini | 70 +++--- ...le-event-handler-settings-objects.html.ini | 2 +- .../realtimeanalyser-fft-scaling.html.ini | 1 - .../sub-sample-buffer-stitching.html.ini | 3 + .../tests/element_click/events.py.ini | 4 + .../webmessaging/with-ports/017.html.ini | 5 - .../webmessaging/with-ports/018.html.ini | 5 + .../Worker/Worker-constructor.html.ini | 2 - .../idlharness.window.js | 8 +- ...iveelement-after-focusing-out-iframes.html | 50 +++++ ...ith-different-site-intermediate-frame.html | 17 ++ ...s-with-same-as-top-intermediate-frame.html | 17 ++ ...ith-different-site-intermediate-frame.html | 17 ++ ...s-with-same-as-top-intermediate-frame.html | 17 ++ ...-out-different-site-iframes-outer.sub.html | 34 +++ ...ment-after-focusing-out-iframes-inner.html | 38 ++++ ...-focusing-out-same-site-iframes-outer.html | 34 +++ ...fferent-site-intermediate-frame-inner.html | 13 ++ ...nt-site-intermediate-frame-middle.sub.html | 37 ++++ ...ent-site-intermediate-frame-outer.sub.html | 22 ++ ...-same-as-top-intermediate-frame-inner.html | 13 ++ ...-as-top-intermediate-frame-middle.sub.html | 37 ++++ ...-same-as-top-intermediate-frame-outer.html | 22 ++ ...fferent-site-intermediate-frame-inner.html | 13 ++ ...nt-site-intermediate-frame-middle.sub.html | 37 ++++ ...ent-site-intermediate-frame-outer.sub.html | 22 ++ ...-same-as-top-intermediate-frame-inner.html | 13 ++ ...-as-top-intermediate-frame-middle.sub.html | 37 ++++ ...-same-as-top-intermediate-frame-outer.html | 22 ++ .../focus/focus-management/focus-events.html | 1 + .../interfaces/custom-state-pseudo-class.idl | 8 +- tests/wpt/web-platform-tests/lint.ignore | 4 + ...intercapture_release_pending_capture.html} | 17 +- ...rcapture_release_right_after_capture.html} | 17 +- ...ure_override_pending_capture_element.html} | 17 +- ...pointercapture_to_same_element_twice.html} | 17 +- .../shadow-dom/ShadowRoot-interface.html | 9 +- .../tools/wptserve/wptserve/stash.py | 5 +- .../webdriver/tests/element_click/events.py | 33 +++ .../support/test_click_wdspec.html | 100 +++++++++ .../tests/perform_actions/key_events.py | 3 +- .../tests/perform_actions/pointer.py | 3 +- .../perform_actions/pointer_contextmenu.py | 3 +- .../tests/perform_actions/pointer_dblclick.py | 3 +- .../perform_actions/pointer_modifier_click.py | 3 +- .../perform_actions/pointer_pause_dblclick.py | 3 +- .../perform_actions/pointer_tripleclick.py | 3 +- .../tests/perform_actions/support/refine.py | 9 - .../webdriver/tests/perform_actions/wheel.py | 3 +- .../tests/release_actions/sequence.py | 3 +- .../tests/release_actions/support/refine.py | 9 - .../webdriver/tests/support/helpers.py | 8 + 91 files changed, 1112 insertions(+), 201 deletions(-) create mode 100644 tests/wpt/metadata-layout-2020/FileAPI/url/url-charset.window.js.ini create mode 100644 tests/wpt/metadata-layout-2020/css/CSS2/floats/hit-test-floats-004.html.ini delete mode 100644 tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPoint-001.html.ini delete mode 100644 tests/wpt/metadata-layout-2020/css/cssom-view/matchMedia-display-none-iframe.html.ini rename tests/wpt/metadata-layout-2020/html/browsers/history/the-history-interface/{traverse_the_history_5.html.ini => traverse_the_history_4.html.ini} (71%) create mode 100644 tests/wpt/metadata-layout-2020/html/interaction/focus/focus-management/focus-events.html.ini create mode 100644 tests/wpt/metadata-layout-2020/webdriver/tests/element_click/events.py.ini delete mode 100644 tests/wpt/metadata-layout-2020/webmessaging/with-ports/017.html.ini create mode 100644 tests/wpt/metadata-layout-2020/webmessaging/with-ports/018.html.ini delete mode 100644 tests/wpt/metadata-layout-2020/workers/constructors/Worker/Worker-constructor.html.ini create mode 100644 tests/wpt/metadata/FileAPI/url/url-charset.window.js.ini create mode 100644 tests/wpt/metadata/css/CSS2/floats/hit-test-floats-004.html.ini delete mode 100644 tests/wpt/metadata/css/cssom-view/elementFromPoint-001.html.ini delete mode 100644 tests/wpt/metadata/css/cssom-view/matchMedia-display-none-iframe.html.ini rename tests/wpt/metadata/html/browsers/history/the-history-interface/{traverse_the_history_5.html.ini => traverse_the_history_4.html.ini} (71%) create mode 100644 tests/wpt/metadata/html/interaction/focus/focus-management/focus-events.html.ini create mode 100644 tests/wpt/metadata/webdriver/tests/element_click/events.py.ini delete mode 100644 tests/wpt/metadata/webmessaging/with-ports/017.html.ini create mode 100644 tests/wpt/metadata/webmessaging/with-ports/018.html.ini delete mode 100644 tests/wpt/metadata/workers/constructors/Worker/Worker-constructor.html.ini create mode 100644 tests/wpt/web-platform-tests/focus/iframe-activeelement-after-focusing-out-iframes.html create mode 100644 tests/wpt/web-platform-tests/focus/iframe-contentwindow-focus-with-different-site-intermediate-frame.html create mode 100644 tests/wpt/web-platform-tests/focus/iframe-contentwindow-focus-with-same-as-top-intermediate-frame.html create mode 100644 tests/wpt/web-platform-tests/focus/iframe-focus-with-different-site-intermediate-frame.html create mode 100644 tests/wpt/web-platform-tests/focus/iframe-focus-with-same-as-top-intermediate-frame.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-different-site-iframes-outer.sub.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-iframes-inner.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-same-site-iframes-outer.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-inner.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-middle.sub.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-outer.sub.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-inner.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-middle.sub.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-outer.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-inner.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-middle.sub.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-outer.sub.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-inner.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-middle.sub.html create mode 100644 tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-outer.html rename tests/wpt/web-platform-tests/pointerevents/{pointerevent_element_haspointercapture_release_pending_capture-manual.html => pointerevent_element_haspointercapture_release_pending_capture.html} (83%) rename tests/wpt/web-platform-tests/pointerevents/{pointerevent_releasepointercapture_release_right_after_capture-manual.html => pointerevent_releasepointercapture_release_right_after_capture.html} (78%) rename tests/wpt/web-platform-tests/pointerevents/{pointerevent_setpointercapture_override_pending_capture_element-manual.html => pointerevent_setpointercapture_override_pending_capture_element.html} (80%) rename tests/wpt/web-platform-tests/pointerevents/{pointerevent_setpointercapture_to_same_element_twice-manual.html => pointerevent_setpointercapture_to_same_element_twice.html} (80%) create mode 100644 tests/wpt/web-platform-tests/webdriver/tests/element_click/events.py create mode 100644 tests/wpt/web-platform-tests/webdriver/tests/element_click/support/test_click_wdspec.html diff --git a/tests/wpt/metadata-layout-2020/FileAPI/url/url-charset.window.js.ini b/tests/wpt/metadata-layout-2020/FileAPI/url/url-charset.window.js.ini new file mode 100644 index 00000000000..a9005e45d6e --- /dev/null +++ b/tests/wpt/metadata-layout-2020/FileAPI/url/url-charset.window.js.ini @@ -0,0 +1,8 @@ +[url-charset.window.html] + expected: TIMEOUT + [Blob charset should override any auto-detected charset.] + expected: TIMEOUT + + [Blob charset should override .] + expected: TIMEOUT + 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-004.html.ini new file mode 100644 index 00000000000..4bfb0c2053a --- /dev/null +++ b/tests/wpt/metadata-layout-2020/css/CSS2/floats/hit-test-floats-004.html.ini @@ -0,0 +1,4 @@ +[hit-test-floats-004.html] + [Miss float below something else] + expected: FAIL + diff --git a/tests/wpt/metadata-layout-2020/css/css-transforms/transform-scale-hittest.html.ini b/tests/wpt/metadata-layout-2020/css/css-transforms/transform-scale-hittest.html.ini index f8e7e539aae..4a1e8110f6f 100644 --- a/tests/wpt/metadata-layout-2020/css/css-transforms/transform-scale-hittest.html.ini +++ b/tests/wpt/metadata-layout-2020/css/css-transforms/transform-scale-hittest.html.ini @@ -2,6 +2,3 @@ [Hit test intersecting scaled box] expected: FAIL - [Hit test within unscaled box] - expected: FAIL - diff --git a/tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPoint-001.html.ini b/tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPoint-001.html.ini deleted file mode 100644 index e38782d8c85..00000000000 --- a/tests/wpt/metadata-layout-2020/css/cssom-view/elementFromPoint-001.html.ini +++ /dev/null @@ -1,4 +0,0 @@ -[elementFromPoint-001.html] - [CSSOM View - 5 - extensions to the Document interface] - expected: FAIL - diff --git a/tests/wpt/metadata-layout-2020/css/cssom-view/matchMedia-display-none-iframe.html.ini b/tests/wpt/metadata-layout-2020/css/cssom-view/matchMedia-display-none-iframe.html.ini deleted file mode 100644 index e6e1f29e274..00000000000 --- a/tests/wpt/metadata-layout-2020/css/cssom-view/matchMedia-display-none-iframe.html.ini +++ /dev/null @@ -1,2 +0,0 @@ -[matchMedia-display-none-iframe.html] - expected: ERROR 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 25d4f2b1265..9bf73d83817 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 @@ -309,15 +309,21 @@ [Response: combined response Content-Type: text/html;" \\" text/plain ";charset=GBK] expected: NOTRUN - [ + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-iframes-inner.html b/tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-iframes-inner.html new file mode 100644 index 00000000000..a94af6b9fba --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-iframes-inner.html @@ -0,0 +1,38 @@ + + + + + iframe active element inner document + + +

Inner


+ + + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-same-site-iframes-outer.html b/tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-same-site-iframes-outer.html new file mode 100644 index 00000000000..98399deb7b6 --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-activeelement-after-focusing-out-same-site-iframes-outer.html @@ -0,0 +1,34 @@ + + +iframe active element after focusing out same site iframes outer +
+ + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-inner.html b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-inner.html new file mode 100644 index 00000000000..c4997f5bd4f --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-inner.html @@ -0,0 +1,13 @@ + + + + iframe.contentWindow.focus() with different-site intermediate frame inner + + + + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-middle.sub.html b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-middle.sub.html new file mode 100644 index 00000000000..e3a5facf82e --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-middle.sub.html @@ -0,0 +1,37 @@ + + +iframe.contentWindow.focus() with different-site intermediate frame middle + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-outer.sub.html b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-outer.sub.html new file mode 100644 index 00000000000..9dbb6af9d9a --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-outer.sub.html @@ -0,0 +1,22 @@ + + +iframe.contentWindow.focus() with different-site intermediate frame outer + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-inner.html b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-inner.html new file mode 100644 index 00000000000..30be12aa811 --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-inner.html @@ -0,0 +1,13 @@ + + + + iframe.contentWindow.focus() with same-as-top intermediate frame inner + + + + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-middle.sub.html b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-middle.sub.html new file mode 100644 index 00000000000..747e1467466 --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-middle.sub.html @@ -0,0 +1,37 @@ + + +iframe.contentWindow.focus() with same-as-top intermediate frame middle + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-outer.html b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-outer.html new file mode 100644 index 00000000000..71cfe78c0d7 --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-contentwindow-focus-with-same-as-top-intermediate-frame-outer.html @@ -0,0 +1,22 @@ + + +iframe.contentWindow.focus() with same-as-top intermediate frame outer + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-inner.html b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-inner.html new file mode 100644 index 00000000000..e2adcc06b20 --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-inner.html @@ -0,0 +1,13 @@ + + + + iframe.focus() with different-site intermediate frame inner + + + + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-middle.sub.html b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-middle.sub.html new file mode 100644 index 00000000000..647f8928d6d --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-middle.sub.html @@ -0,0 +1,37 @@ + + +iframe.focus() with different-site intermediate frame middle + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-outer.sub.html b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-outer.sub.html new file mode 100644 index 00000000000..5e80410206d --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-different-site-intermediate-frame-outer.sub.html @@ -0,0 +1,22 @@ + + +iframe.focus() with different-site intermediate frame outer + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-inner.html b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-inner.html new file mode 100644 index 00000000000..c55c5b44998 --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-inner.html @@ -0,0 +1,13 @@ + + + + iframe.focus() with same-as-top intermediate frame inner + + + + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-middle.sub.html b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-middle.sub.html new file mode 100644 index 00000000000..9fdbc3c3582 --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-middle.sub.html @@ -0,0 +1,37 @@ + + +iframe.focus() with same-as-top intermediate frame middle + + diff --git a/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-outer.html b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-outer.html new file mode 100644 index 00000000000..3f6085a739c --- /dev/null +++ b/tests/wpt/web-platform-tests/focus/support/iframe-focus-with-same-as-top-intermediate-frame-outer.html @@ -0,0 +1,22 @@ + + +iframe.focus() with same-as-top intermediate frame outer + + diff --git a/tests/wpt/web-platform-tests/html/interaction/focus/focus-management/focus-events.html b/tests/wpt/web-platform-tests/html/interaction/focus/focus-management/focus-events.html index d63362aaa18..5f8ca20a13d 100644 --- a/tests/wpt/web-platform-tests/html/interaction/focus/focus-management/focus-events.html +++ b/tests/wpt/web-platform-tests/html/interaction/focus/focus-management/focus-events.html @@ -25,6 +25,7 @@ assert_true(e.isTrusted, "blur event is trusted"); assert_false(e.bubbles, "blur event doesn't bubble"); assert_false(e.cancelable, "blur event is not cancelable"); + assert_equals(document.activeElement, document.body); }); i1.focus(); diff --git a/tests/wpt/web-platform-tests/interfaces/custom-state-pseudo-class.idl b/tests/wpt/web-platform-tests/interfaces/custom-state-pseudo-class.idl index d4e3da7e6a1..342f1ede0b0 100644 --- a/tests/wpt/web-platform-tests/interfaces/custom-state-pseudo-class.idl +++ b/tests/wpt/web-platform-tests/interfaces/custom-state-pseudo-class.idl @@ -4,5 +4,11 @@ // Source: Custom State Pseudo Class (https://wicg.github.io/custom-state-pseudo-class/) partial interface ElementInternals { - [SameObject, PutForwards=value] readonly attribute DOMTokenList states; + readonly attribute CustomStateSet states; +}; + +[Exposed=Window] +interface CustomStateSet { + setlike; + undefined add(DOMString value); }; diff --git a/tests/wpt/web-platform-tests/lint.ignore b/tests/wpt/web-platform-tests/lint.ignore index 2e0fc8b39bc..ab3d0e51570 100644 --- a/tests/wpt/web-platform-tests/lint.ignore +++ b/tests/wpt/web-platform-tests/lint.ignore @@ -214,6 +214,10 @@ SET TIMEOUT: webvtt/* SET TIMEOUT: workers/* SET TIMEOUT: xhr/resources/init.htm SET TIMEOUT: xhr/resources/xmlhttprequest-timeout.js +SET TIMEOUT: focus/support/iframe-focus-with-different-site-intermediate-frame-outer.sub.html +SET TIMEOUT: focus/support/iframe-focus-with-different-site-intermediate-frame-middle.sub.html +SET TIMEOUT: focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-outer.sub.html +SET TIMEOUT: focus/support/iframe-contentwindow-focus-with-different-site-intermediate-frame-middle.sub.html # generate_tests implementation and sample usage GENERATE_TESTS: resources/test/tests/functional/generate-callback.html diff --git a/tests/wpt/web-platform-tests/pointerevents/pointerevent_element_haspointercapture_release_pending_capture-manual.html b/tests/wpt/web-platform-tests/pointerevents/pointerevent_element_haspointercapture_release_pending_capture.html similarity index 83% rename from tests/wpt/web-platform-tests/pointerevents/pointerevent_element_haspointercapture_release_pending_capture-manual.html rename to tests/wpt/web-platform-tests/pointerevents/pointerevent_element_haspointercapture_release_pending_capture.html index 17ad3e24ba4..e75dff86752 100644 --- a/tests/wpt/web-platform-tests/pointerevents/pointerevent_element_haspointercapture_release_pending_capture-manual.html +++ b/tests/wpt/web-platform-tests/pointerevents/pointerevent_element_haspointercapture_release_pending_capture.html @@ -6,8 +6,12 @@ + + + diff --git a/tests/wpt/web-platform-tests/pointerevents/pointerevent_releasepointercapture_release_right_after_capture-manual.html b/tests/wpt/web-platform-tests/pointerevents/pointerevent_releasepointercapture_release_right_after_capture.html similarity index 78% rename from tests/wpt/web-platform-tests/pointerevents/pointerevent_releasepointercapture_release_right_after_capture-manual.html rename to tests/wpt/web-platform-tests/pointerevents/pointerevent_releasepointercapture_release_right_after_capture.html index 8f64b920873..409951b918a 100644 --- a/tests/wpt/web-platform-tests/pointerevents/pointerevent_releasepointercapture_release_right_after_capture-manual.html +++ b/tests/wpt/web-platform-tests/pointerevents/pointerevent_releasepointercapture_release_right_after_capture.html @@ -6,8 +6,12 @@ + + + diff --git a/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_override_pending_capture_element-manual.html b/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_override_pending_capture_element.html similarity index 80% rename from tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_override_pending_capture_element-manual.html rename to tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_override_pending_capture_element.html index 4e4818c21b7..f7c1d429919 100644 --- a/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_override_pending_capture_element-manual.html +++ b/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_override_pending_capture_element.html @@ -6,8 +6,12 @@ + + + diff --git a/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_to_same_element_twice-manual.html b/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_to_same_element_twice.html similarity index 80% rename from tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_to_same_element_twice-manual.html rename to tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_to_same_element_twice.html index 161c5c2fcb9..5225ac508d4 100644 --- a/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_to_same_element_twice-manual.html +++ b/tests/wpt/web-platform-tests/pointerevents/pointerevent_setpointercapture_to_same_element_twice.html @@ -6,8 +6,12 @@ + + + diff --git a/tests/wpt/web-platform-tests/shadow-dom/ShadowRoot-interface.html b/tests/wpt/web-platform-tests/shadow-dom/ShadowRoot-interface.html index 8efa50e4ea1..e95b1d9542e 100644 --- a/tests/wpt/web-platform-tests/shadow-dom/ShadowRoot-interface.html +++ b/tests/wpt/web-platform-tests/shadow-dom/ShadowRoot-interface.html @@ -96,12 +96,19 @@ function testStyleSheets(mode) { shadowRoot.innerHTML = ''; assert_equals(shadowRoot.styleSheets.length, 0, 'shadowRoot.styleSheets must be empty when the shadow root is not connected'); + var styles = shadowRoot.querySelectorAll('style'); + assert_equals(styles[0].sheet, null, "Sheet should be null in a disconnected tree"); + assert_equals(styles[1].sheet, null, "Sheet should be null in a disconnected tree"); document.body.appendChild(host); assert_equals(shadowRoot.styleSheets.length, 2, 'shadowRoot.styleSheets must contain two items when the shadow root has two style elements'); - var styles = shadowRoot.querySelectorAll('style'); assert_equals(shadowRoot.styleSheets[0], styles[0].sheet, 'shadowRoot.styleSheets[0] must be the first style element in the shadow root'); assert_equals(shadowRoot.styleSheets[1], styles[1].sheet, 'shadowRoot.styleSheets[1] must be the second style element in the shadow root'); + + host.remove(); + assert_equals(shadowRoot.styleSheets.length, 0, 'shadowRoot.styleSheets must be empty when the shadow root is not connected'); + assert_equals(styles[0].sheet, null, "Sheet should be null in a disconnected tree"); + assert_equals(styles[1].sheet, null, "Sheet should be null in a disconnected tree"); }, 'ShadowRoot.styleSheets must return a StyleSheetList sequence containing the shadow root style sheets when shadow root is ' + mode + '.'); } diff --git a/tests/wpt/web-platform-tests/tools/wptserve/wptserve/stash.py b/tests/wpt/web-platform-tests/tools/wptserve/wptserve/stash.py index 535355a8287..bf6e59927be 100644 --- a/tests/wpt/web-platform-tests/tools/wptserve/wptserve/stash.py +++ b/tests/wpt/web-platform-tests/tools/wptserve/wptserve/stash.py @@ -75,7 +75,10 @@ def start_server(address=None, authkey=None, mp_context=None): manager = ServerDictManager(address, authkey, **kwargs) manager.start() - return (manager, manager._address, manager._authkey) + address = manager._address + if isinstance(address, bytes): + address = address.decode("ascii") + return (manager, address, manager._authkey) class LockWrapper(object): diff --git a/tests/wpt/web-platform-tests/webdriver/tests/element_click/events.py b/tests/wpt/web-platform-tests/webdriver/tests/element_click/events.py new file mode 100644 index 00000000000..e3d32c1bcb4 --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/tests/element_click/events.py @@ -0,0 +1,33 @@ +from webdriver import Element +from tests.support.asserts import assert_success +from tests.support.helpers import filter_dict + +def get_events(session): + """Return list of mouse events recorded in the fixture.""" + return session.execute_script("return allEvents.events;") or [] + +def element_click(session, element): + return session.transport.send( + "POST", "session/{session_id}/element/{element_id}/click".format( + session_id=session.session_id, + element_id=element.id)) + +def test_event_mousemove(session, url): + session.url = url("/webdriver/tests/element_click/support/test_click_wdspec.html") + + element = session.find.css('#outer', all=False) + response = element_click(session, element) + assert_success(response) + + events = get_events(session) + assert len(events) == 4 + + expected = [ + {"type": "mousemove", "buttons": 0, "button": 0}, + {"type": "mousedown", "buttons": 1, "button": 0}, + {"type": "mouseup", "buttons": 0, "button": 0}, + {"type": "click", "buttons": 0, "button": 0}, + ] + filtered_events = [filter_dict(e, expected[0]) for e in events] + + assert expected == filtered_events diff --git a/tests/wpt/web-platform-tests/webdriver/tests/element_click/support/test_click_wdspec.html b/tests/wpt/web-platform-tests/webdriver/tests/element_click/support/test_click_wdspec.html new file mode 100644 index 00000000000..a9451ec82be --- /dev/null +++ b/tests/wpt/web-platform-tests/webdriver/tests/element_click/support/test_click_wdspec.html @@ -0,0 +1,100 @@ + + + + + Test Element Click + + + + +
+
+

ClickReporter

+
+
+
+
+

Events

+
+
+ + diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/key_events.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/key_events.py index c3958015bfd..8dbe024d183 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/key_events.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/key_events.py @@ -5,7 +5,8 @@ from collections import defaultdict import pytest from tests.perform_actions.support.keys import ALL_EVENTS, Keys, ALTERNATIVE_KEY_NAMES -from tests.perform_actions.support.refine import filter_dict, get_events, get_keys +from tests.perform_actions.support.refine import get_events, get_keys +from tests.support.helpers import filter_dict def test_keyup_only_sends_no_events(session, key_reporter, key_chain): diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer.py index 9579a57aa72..674d46d7b61 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer.py @@ -5,8 +5,9 @@ import pytest from webdriver.error import NoSuchWindowException from tests.perform_actions.support.mouse import get_inview_center, get_viewport_rect -from tests.perform_actions.support.refine import filter_dict, get_events +from tests.perform_actions.support.refine import get_events from tests.support.asserts import assert_move_to_coordinates +from tests.support.helpers import filter_dict from tests.support.sync import Poll diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_contextmenu.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_contextmenu.py index fda3f18bbc1..50f684327f2 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_contextmenu.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_contextmenu.py @@ -1,7 +1,8 @@ import pytest from tests.perform_actions.support.keys import Keys -from tests.perform_actions.support.refine import filter_dict, get_events +from tests.perform_actions.support.refine import get_events +from tests.support.helpers import filter_dict @pytest.mark.parametrize("modifier, prop", [ diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_dblclick.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_dblclick.py index 8c89cef5f38..5be635a4d56 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_dblclick.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_dblclick.py @@ -1,7 +1,8 @@ import pytest -from tests.perform_actions.support.refine import filter_dict, get_events +from tests.perform_actions.support.refine import get_events from tests.support.asserts import assert_move_to_coordinates +from tests.support.helpers import filter_dict @pytest.mark.parametrize("click_pause", [0, 200]) diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_modifier_click.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_modifier_click.py index ba81f6d090b..28c4086e0f8 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_modifier_click.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_modifier_click.py @@ -1,7 +1,8 @@ import pytest from tests.perform_actions.support.keys import Keys -from tests.perform_actions.support.refine import filter_dict, get_events +from tests.perform_actions.support.refine import get_events +from tests.support.helpers import filter_dict @pytest.mark.parametrize("modifier, prop", [ diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_pause_dblclick.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_pause_dblclick.py index 85679f3614a..d46178a1d65 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_pause_dblclick.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_pause_dblclick.py @@ -1,5 +1,6 @@ from tests.perform_actions.support.mouse import get_inview_center, get_viewport_rect -from tests.perform_actions.support.refine import filter_dict, get_events +from tests.perform_actions.support.refine import get_events +from tests.support.helpers import filter_dict _DBLCLICK_INTERVAL = 640 diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_tripleclick.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_tripleclick.py index 3bf41bab849..8239fc2a606 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_tripleclick.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/pointer_tripleclick.py @@ -1,5 +1,6 @@ -from tests.perform_actions.support.refine import filter_dict, get_events +from tests.perform_actions.support.refine import get_events from tests.support.asserts import assert_move_to_coordinates +from tests.support.helpers import filter_dict lots_of_text = "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor "\ "incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud "\ diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/support/refine.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/support/refine.py index d5d24e934f6..35c962b9ecb 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/support/refine.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/support/refine.py @@ -27,12 +27,3 @@ def get_keys(input_el): return "" else: return rv - - -def filter_dict(source, d): - """Filter `source` dict to only contain same keys as `d` dict. - - :param source: dictionary to filter. - :param d: dictionary whose keys determine the filtering. - """ - return {k: source[k] for k in d.keys()} diff --git a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/wheel.py b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/wheel.py index fc84f2f2e01..67734800b19 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/wheel.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/perform_actions/wheel.py @@ -2,8 +2,9 @@ import pytest from webdriver.error import NoSuchWindowException -from tests.perform_actions.support.refine import filter_dict, get_events +from tests.perform_actions.support.refine import get_events from tests.support.asserts import assert_move_to_coordinates +from tests.support.helpers import filter_dict def test_null_response_value(session, wheel_chain): diff --git a/tests/wpt/web-platform-tests/webdriver/tests/release_actions/sequence.py b/tests/wpt/web-platform-tests/webdriver/tests/release_actions/sequence.py index 2d816f8094b..75143d85ca6 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/release_actions/sequence.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/release_actions/sequence.py @@ -1,6 +1,7 @@ # META: timeout=long -from tests.release_actions.support.refine import filter_dict, get_events, get_keys +from tests.release_actions.support.refine import get_events, get_keys +from tests.support.helpers import filter_dict def test_release_no_actions_sends_no_events(session, key_reporter): diff --git a/tests/wpt/web-platform-tests/webdriver/tests/release_actions/support/refine.py b/tests/wpt/web-platform-tests/webdriver/tests/release_actions/support/refine.py index 3a6d63e04ce..90f722587c3 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/release_actions/support/refine.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/release_actions/support/refine.py @@ -22,12 +22,3 @@ def get_keys(input_el): return "" else: return rv - - -def filter_dict(source, d): - """Filter `source` dict to only contain same keys as `d` dict. - - :param source: dictionary to filter. - :param d: dictionary whose keys determine the filtering. - """ - return {k: source[k] for k in d.keys()} diff --git a/tests/wpt/web-platform-tests/webdriver/tests/support/helpers.py b/tests/wpt/web-platform-tests/webdriver/tests/support/helpers.py index a1082caf58c..13607e30481 100644 --- a/tests/wpt/web-platform-tests/webdriver/tests/support/helpers.py +++ b/tests/wpt/web-platform-tests/webdriver/tests/support/helpers.py @@ -238,3 +238,11 @@ def available_screen_size(session): screen.availHeight - screen.availTop, ]; """)) + +def filter_dict(source, d): + """Filter `source` dict to only contain same keys as `d` dict. + + :param source: dictionary to filter. + :param d: dictionary whose keys determine the filtering. + """ + return {k: source[k] for k in d.keys()}