Bug 1432864 - Unfocussing steps will target <body> element. r=automatedtester a=test-only
authorAndreas Tolfsen <ato@sny.no>
Thu, 01 Feb 2018 09:04:00 +0200
changeset 454624 11887cd21e75fcb2a1dd94ad7bd49d81a2acbfe3
parent 454623 cc6e54bee19e7153ae5ac6cc7887805f001c2470
child 454625 7b20f617fd153301eff11f4f892e6dab460ea191
push id1648
push usermtabara@mozilla.com
push dateThu, 01 Mar 2018 12:45:47 +0000
treeherdermozilla-release@cbb9688c2eeb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersautomatedtester, test-only
bugs1432864
milestone59.0
Bug 1432864 - Unfocussing steps will target <body> element. r=automatedtester a=test-only The WebDriver Element Send Keys command is meant to run the HTML unfocussing steps after clearing the element. When HTMLElement.blur() is called on the root document element (<html>) it is the <body> that is in focus when the unfocussing steps have run. The same applies in the case of typing into an <iframe> element. The controlling element of the <iframe> is the <body>, as this is the element ath will receive focus should you blur the frame. MozReview-Commit-ID: 19Ox3W9CF8O
testing/web-platform/meta/MANIFEST.json
testing/web-platform/tests/webdriver/tests/element_send_keys/interactability.py
--- a/testing/web-platform/meta/MANIFEST.json
+++ b/testing/web-platform/meta/MANIFEST.json
@@ -493549,17 +493549,17 @@
    "a736f68dc602c0fccab56ec5cc6234cb3298c88d",
    "support"
   ],
   "css/css-scoping/shadow-cascade-order-001.html": [
    "46913ea7e47811b11be898de5c3bd0a330ea6637",
    "testharness"
   ],
   "css/css-scoping/slotted-invalidation.html": [
-   "b22e8258671a8709a3ce6fdc42501b43b866e946",
+   "c500e1ceba1b293d45df5f66fd89d4a5d9ceb952",
    "testharness"
   ],
   "css/css-scoping/slotted-parsing.html": [
    "6bac5b15011d7177a40f7ca3e3c5f7e410643920",
    "testharness"
   ],
   "css/css-scoping/slotted-with-pseudo-element-ref.html": [
    "48561a3dff973b7ad1bfa9702461e50fd4a67c2d",
@@ -520797,17 +520797,17 @@
    "394ad01c928f8a15796bc6c29cdbc5e2dc37fd52",
    "testharness"
   ],
   "css/selectors/invalidation/any-link-pseudo.html": [
    "9593a7d2dddc79525edb801748a28b1a5a1837c7",
    "testharness"
   ],
   "css/selectors/invalidation/selectorText-dynamic-001.html": [
-   "ab36d3d2b9f8e3b610f60a4b8859c95bf239eb43",
+   "a0cd9f73bca0065eaf8b92ca2c61c858dbedb147",
    "testharness"
   ],
   "css/selectors/invalidation/sheet-going-away-001.html": [
    "ac8bac5fe4663c70de2ee449fd0cf432d7a82eff",
    "testharness"
   ],
   "css/selectors/invalidation/sheet-going-away-002-ref.html": [
    "5616ec15bb322f49c4b28761df2cfb40fdafc226",
@@ -583317,17 +583317,17 @@
    "020bcd036daed8eb8928c2924ea1d04050cf1939",
    "support"
   ],
   "webdriver/README.md": [
    "185acb69e9516e0564e16bf7d7f8dc2a4c48d3c7",
    "support"
   ],
   "webdriver/tests/__init__.py": [
-   "da39a3ee5e6b4b0d3255bfef95601890afd80709",
+   "b2ebe4b632b1a75e7334b97c3df7075f494dd5c6",
    "support"
   ],
   "webdriver/tests/actions/__init__.py": [
    "da39a3ee5e6b4b0d3255bfef95601890afd80709",
    "support"
   ],
   "webdriver/tests/actions/conftest.py": [
    "f366a25d9d5e35a2897413a265398bc7a54f7c44",
@@ -583341,21 +583341,21 @@
    "dbe27dd0b1625169fc8cc2055f8fb49d5a4a78d2",
    "wdspec"
   ],
   "webdriver/tests/actions/modifier_click.py": [
    "88a384182fdd9df1515b9d8cfda8f56aed138ec7",
    "wdspec"
   ],
   "webdriver/tests/actions/mouse.py": [
-   "0af689cee458ed260b2b9cc6f3231c314a3a6638",
+   "708373af0d50f2a0a9776743848482c939f90ec8",
    "wdspec"
   ],
   "webdriver/tests/actions/mouse_dblclick.py": [
-   "61bab159bf1ccc7d44e4034a3e67d60b13fc1607",
+   "154d595a3d4466a44c5217c54bb3c717d9a2b9ec",
    "wdspec"
   ],
   "webdriver/tests/actions/sequence.py": [
    "d43caf0f8607a76c3baed7806664b686bde21fda",
    "wdspec"
   ],
   "webdriver/tests/actions/special_keys.py": [
    "64eb2401664b71d68f7b53e236a947eec6d651cc",
@@ -583365,17 +583365,17 @@
    "da39a3ee5e6b4b0d3255bfef95601890afd80709",
    "support"
   ],
   "webdriver/tests/actions/support/keys.py": [
    "528ab8473914c14f9671d89b8a888d30162714ec",
    "support"
   ],
   "webdriver/tests/actions/support/mouse.py": [
-   "0a6fca5e3fe20db114dbee1dd9d290ec343f6f9c",
+   "208a1c4fbc0d5c542d17de7f6474d477ce1feb45",
    "support"
   ],
   "webdriver/tests/actions/support/refine.py": [
    "0d244bffe67ef57be68aad99f1cbc7440ff80e27",
    "support"
   ],
   "webdriver/tests/actions/support/test_actions_wdspec.html": [
    "95203777fcc012ab64465287737a89a4ba2c31dc",
@@ -583453,17 +583453,17 @@
    "7d40a7641dbf04cd78f1dba630afa2e8d80dad13",
    "wdspec"
   ],
   "webdriver/tests/element_send_keys/__init__.py": [
    "da39a3ee5e6b4b0d3255bfef95601890afd80709",
    "support"
   ],
   "webdriver/tests/element_send_keys/interactability.py": [
-   "bd7cd6c009c86fe93c0e132c30fb9674413962d4",
+   "bd5d26173017dc3cbdc282809028639a7b4a214a",
    "wdspec"
   ],
   "webdriver/tests/element_send_keys/scroll_into_view.py": [
    "fb192d5d1d93aa729b07cadcadfa630587bd0b39",
    "wdspec"
   ],
   "webdriver/tests/execute_async_script/user_prompts.py": [
    "e31edd4537f9b7479a348465154381f5b18f938c",
@@ -583481,17 +583481,17 @@
    "817011a8cdff7cfd7e445fb8ecb84e5d91f03993",
    "wdspec"
   ],
   "webdriver/tests/get_window_rect.py": [
    "c9139c16aa950c734c776887d6a762b867790812",
    "wdspec"
   ],
   "webdriver/tests/interaction/element_clear.py": [
-   "46f145bac93316b5f93d565e9e2389499771ff24",
+   "2f952f10fdc4d772d614cb9e1a081f6b22327319",
    "wdspec"
   ],
   "webdriver/tests/interaction/send_keys_content_editable.py": [
    "9c071e60e1203cf31120f20874b5f38ba41dacc3",
    "wdspec"
   ],
   "webdriver/tests/interface.html": [
    "6625887cfa7f461dc428c11861fce71c47bef57d",
@@ -583585,17 +583585,17 @@
    "570274d59020c4d8d0b8ecd604660ee7d710a165",
    "wdspec"
   ],
   "webdriver/tests/support/__init__.py": [
    "5a31a3917a5157516c10951a3b3d5ffb43b992d9",
    "support"
   ],
   "webdriver/tests/support/asserts.py": [
-   "68bb420a9d85810c9fd8b6eaa569b855dfb83638",
+   "1b839404daaca1d059cba98377edb91691ef7e82",
    "support"
   ],
   "webdriver/tests/support/fixtures.py": [
    "b9b62366cd60ae7167ad2d0efdf3790ae2e780a4",
    "support"
   ],
   "webdriver/tests/support/http_request.py": [
    "cb40c781fea2280b98135522def5e6a116d7b946",
--- a/testing/web-platform/tests/webdriver/tests/element_send_keys/interactability.py
+++ b/testing/web-platform/tests/webdriver/tests/element_send_keys/interactability.py
@@ -41,17 +41,17 @@ def test_document_element_is_interactabl
     element = session.find.css(":root", all=False)
     result = session.find.css("input", all=False)
 
     # By default body is the active element
     assert_same_element(session, body, session.active_element)
 
     response = send_keys_to_element(session, element, "foo")
     assert_success(response)
-    assert_same_element(session, element, session.active_element)
+    assert_same_element(session, body, session.active_element)
     assert result.property("value") == "foo"
 
 
 def test_iframe_is_interactable(session):
     session.url = inline(iframe("""
         <body onkeypress="document.getElementById('result').value += event.key">
           <input type="text" id="result"/>
         </body>
@@ -60,17 +60,17 @@ def test_iframe_is_interactable(session)
     body = session.find.css("body", all=False)
     frame = session.find.css("iframe", all=False)
 
     # By default the body has the focus
     assert_same_element(session, body, session.active_element)
 
     response = send_keys_to_element(session, frame, "foo")
     assert_success(response)
-    assert_same_element(session, frame, session.active_element)
+    assert_same_element(session, body, session.active_element)
 
     # Any key events are immediately routed to the nested
     # browsing context's active document.
     session.switch_frame(frame)
     result = session.find.css("input", all=False)
     assert result.property("value") == "foo"