[webdriver-bidi] Add tests for browsingContext.locateNodes #42565
Community-TC (pull_request)
Verify that all tests affected by a pull request are stable when executed in chrome.
Details
View task in Taskcluster
View logs in Taskcluster
WPT Command: python3 ./wpt run --channel=dev --verify --verify-no-chaos-mode --verify-repeat-loop=0 --verify-repeat-restart=10 --github-checks-text-file=/home/test/artifacts/checkrun.md --affected base_head --log-mach-level=info --log-mach=- -y --no-pause --no-restart-on-unexpected --install-fonts --no-headless --verify-log-full --enable-swiftshader chrome
Some affected tests had slow results:
Slow tests
Test | Result | Longest duration (ms) | Timeout (ms) |
---|---|---|---|
/webdriver/tests/bidi/browsing_context/locate_nodes/context.py |
OK |
22470 |
25000 |
/webdriver/tests/bidi/browsing_context/locate_nodes/locator.py |
OK |
28679 |
25000 |
These may be pre-existing or newly slow tests. Slow tests indicate that a test ran very close to the test timeout limit and so may become TIMEOUT-flaky in the future. Consider speeding up the test or breaking it into multiple tests. For help, please tag @web-platform-tests/wpt-core-team
in a comment.
'value': {'attributes': {},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}}]
inline = <function inline.<locals>.inline at 0x7f9f145af310>
script_result = {'type': 'nodelist',
'value': [{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_19',
'type': 'node',
'value': {'attributes': {'id': 'parent-one'},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_20',
'type': 'node',
'value': {'attributes': {},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_21',
'type': 'node',
'value': {'attributes': {'id': 'parent-two'},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_22',
'type': 'node',
'value': {'attributes': {},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}}]}
top_context = {'children': [],
'context': 'FD8DD836D5B421F808653CFF724D20C4',
'parent': None,
'url': 'https://web-platform.test:8443/webdriver/tests/support/inline.py?doc=%3C%21doctype+html%3E%0A%3Cmeta+charset%3DUTF-8%3E%0A%0A+++++++++++++++++%3Cp+id%3D%22parent-one%22%3E%3Cdiv+data-class%3D%22one%22%3Efoo%3C%2Fdiv%3E%3Cdiv+data-class%3D%22two%22%3Ebar%3C%2Fdiv%3E%3C%2Fp%3E%0A+++++++++++++++++%3Cp+id%3D%22parent-two%22%3E%3Cdiv+data-class%3D%22one%22%3Efoo%3C%2Fdiv%3E%3Cdiv+data-class%3D%22two%22%3Ebar%3C%2Fdiv%3E%3C%2Fp%3E%0A+++++++++++++++++&mime=text%2Fhtml&charset=UTF-8'}
type = 'innerText'
url = 'https://web-platform.test:8443/webdriver/tests/support/inline.py?doc=%3C%21doctype+html%3E%0A%3Cmeta+charset%3DUTF-8%3E%0A%0A+++++++++++++++++%3Cp+id%3D%22parent-one%22%3E%3Cdiv+data-class%3D%22one%22%3Efoo%3C%2Fdiv%3E%3Cdiv+data-class%3D%22two%22%3Ebar%3C%2Fdiv%3E%3C%2Fp%3E%0A+++++++++++++++++%3Cp+id%3D%22parent-two%22%3E%3Cdiv+data-class%3D%22one%22%3Efoo%3C%2Fdiv%3E%3Cdiv+data-class%3D%22two%22%3Ebar%3C%2Fdiv%3E%3C%2Fp%3E%0A+++++++++++++++++&mime=text%2Fhtml&charset=UTF-8'
value = 'foo'
webdriver/tests/bidi/browsing_context/locate_nodes/start_nodes.py:82:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <webdriver.bidi.modules.browsing_context.BrowsingContext object at 0x7f9f147d3c70>
kwargs = {'context': 'FD8DD836D5B421F808653CFF724D20C4', 'locator': {'type': 'innerText', 'value': 'foo'}, 'start_nodes': [{'sh...lue': {'attributes': {}, 'childNodeCount': 0, 'localName': 'p', 'namespaceURI': 'http://www.w3.org/1999/xhtml', ...}}]}
raw_result = False
params = {'context': 'FD8DD836D5B421F808653CFF724D20C4', 'locator': {'type': 'innerText', 'value': 'foo'}, 'startNodes': [{'sha...lue': {'attributes': {}, 'childNodeCount': 0, 'localName': 'p', 'namespaceURI': 'http://www.w3.org/1999/xhtml', ...}}]}
mod_name = 'browsingContext', cmd_name = 'browsingContext.locateNodes'
future = <[AttributeError("'UnknownCommandException' object has no attribute 'error'") raised in repr()] Future object at 0x7f9f145ae1c0>
@functools.wraps(params_fn)
async def inner(self: Any, **kwargs: Any) -> Any:
raw_result = kwargs.pop("raw_result", False)
params = remove_undefined(params_fn(self, **kwargs))
# Convert the classname and the method name to a bidi command name
mod_name = owner.__name__[0].lower() + owner.__name__[1:]
if hasattr(owner, "prefix"):
mod_name = f"{owner.prefix}:{mod_name}"
cmd_name = f"{mod_name}.{to_camelcase(name)}"
future = await self.session.send_command(cmd_name, params)
> result = await future
E webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)
cmd_name = 'browsingContext.locateNodes'
future = <[AttributeError("'UnknownCommandException' object has no attribute 'error'") raised in repr()] Future object at 0x7f9f145ae1c0>
kwargs = {'context': 'FD8DD836D5B421F808653CFF724D20C4',
'locator': {'type': 'innerText', 'value': 'foo'},
'start_nodes': [{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_19',
'type': 'node',
'value': {'attributes': {'id': 'parent-one'},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_20',
'type': 'node',
'value': {'attributes': {},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_21',
'type': 'node',
'value': {'attributes': {'id': 'parent-two'},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_22',
'type': 'node',
'value': {'attributes': {},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}}]}
mod_name = 'browsingContext'
name = 'locate_nodes'
owner = <class 'webdriver.bidi.modules.browsing_context.BrowsingContext'>
params = {'context': 'FD8DD836D5B421F808653CFF724D20C4',
'locator': {'type': 'innerText', 'value': 'foo'},
'startNodes': [{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_19',
'type': 'node',
'value': {'attributes': {'id': 'parent-one'},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_20',
'type': 'node',
'value': {'attributes': {},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_21',
'type': 'node',
'value': {'attributes': {'id': 'parent-two'},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}},
{'sharedId': '1F9DDB5BD015637A382C1C57CB9BA5A7_element_22',
'type': 'node',
'value': {'attributes': {},
'childNodeCount': 0,
'localName': 'p',
'namespaceURI': 'http://www.w3.org/1999/xhtml',
'nodeType': 1,
'shadowRoot': None}}]}
params_fn = <function BrowsingContext.locate_nodes at 0x7f9f15493e50>
raw_result = False
result_fn = <function BrowsingContext._locate_nodes at 0x7f9f15493ee0>
self = <webdriver.bidi.modules.browsing_context.BrowsingContext object at 0x7f9f147d3c70>
tools/webdriver/webdriver/bidi/modules/_module.py:76: UnknownCommandException
5:09.69 INFO Got 80 unexpected results, with 0 unexpected passes
5:09.70 wptserve INFO Stopped WebTransport over HTTP/3 server on 127.0.0.1:11000
5:09.95 wptserve INFO Stopped http server on 127.0.0.1:8002
5:09.95 wptserve INFO Stopped http server on 127.0.0.1:8000
5:09.95 wptserve INFO Stopped http server on 127.0.0.1:8444
5:09.96 wptserve INFO Stopped http server on 127.0.0.1:8001
5:09.96 wptserve INFO Stopped http server on 127.0.0.1:8446
5:09.96 wptserve INFO Stopped http server on 127.0.0.1:8445
5:09.96 wptserve INFO Stopped http server on 127.0.0.1:9000
5:09.96 wptserve INFO Close on: (<AddressFamily.AF_INET: 2>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('127.0.0.1', 8888))
5:09.96 wptserve INFO Close on: (<AddressFamily.AF_INET: 2>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('127.0.0.1', 8889))
5:09.96 wptserve INFO Stopped http server on 127.0.0.1:8003
5:09.98 wptserve INFO Stopped http server on 127.0.0.1:8443
5:10.07 INFO Removed font: Ahem.ttf
5:10.09 INFO Closing logging queue
5:10.09 INFO queue closed
5:10.34 INFO ::: Ran 10 of expected 10 iterations.
5:10.34 INFO ## All results ##
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/context.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |-------------------------------------|---------|------------------------------------------------------------------------------------------------------------------|
5:10.34 INFO | | OK | |
5:10.34 INFO | `test_params_context_invalid_value` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/invalid.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |---------|---------|----------|
5:10.34 INFO | | ERROR | |
5:10.34 INFO
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/locator.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |---------------------------------------------------------------------------|---------|------------------------------------------------------------------------------------------------------------------|
5:10.34 INFO | | OK | |
5:10.34 INFO | `test_find_by_locator[css-div]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_locator[xpath-//div]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_locator[innerText-foobarBARbaz]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_true_full_match_no_max_depth]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_false_full_match_no_max_depth]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_true_partial_match_no_max_depth]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_false_partial_match_no_max_depth]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_true_full_match_max_depth_zero]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_false_full_match_max_depth_zero]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_true_partial_match_max_depth_zero]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_find_by_inner_text[ignore_case_false_partial_match_max_depth_zero]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/max_node_count.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |---------|---------|----------|
5:10.34 INFO | | ERROR | |
5:10.34 INFO
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/ownership.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |---------|---------|----------|
5:10.34 INFO | | ERROR | |
5:10.34 INFO
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/sandbox.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |----------------------------------------------------------------------------------------------|---------|------------------------------------------------------------------------------------------------------------------|
5:10.34 INFO | | OK | |
5:10.34 INFO | `test_locate_nodes_in_sandbox` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_same_node_in_different_sandboxes_returns_same_id` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_same_node_in_default_sandbox_returns_same_id_as_sandbox` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_same_node_in_different_sandboxes_with_root_ownership_returns_different_handles` | FAIL | `TypeError: Object of type OwnershipModel is not JSON serializable` |
5:10.34 INFO
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/serialization_options.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |---------------------------------------------------|---------|------------------------------------------------------------------------------------------------------------------|
5:10.34 INFO | | OK | |
5:10.34 INFO | `test_locate_nodes_serialization_options[open]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_nodes_serialization_options[closed]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO
5:10.34 INFO ### /webdriver/tests/bidi/browsing_context/locate_nodes/start_nodes.py ###
5:10.34 INFO | Subtest | Results | Messages |
5:10.34 INFO |----------------------------------------------------------------------------|---------|------------------------------------------------------------------------------------------------------------------|
5:10.34 INFO | | OK | |
5:10.34 INFO | `test_locate_with_context_nodes[css-div]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_with_context_nodes[xpath-//div]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_with_context_nodes[innerText-foo]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_with_multiple_context_nodes[css-div[data-class='one']]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_with_multiple_context_nodes[xpath-.//div[@data-class='one']]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO | `test_locate_with_multiple_context_nodes[innerText-foo]` | FAIL | `webdriver.bidi.error.UnknownCommandException: unknown command (Unknown command 'browsingContext.locateNodes'.)` |
5:10.34 INFO
5:10.34 INFO ## Slow tests ##
5:10.34 INFO | Test | Result | Longest duration (ms) | Timeout (ms) |
5:10.34 INFO |------------------------------------------------------------------|--------|-----------------------|--------------|
5:10.34 INFO | `/webdriver/tests/bidi/browsing_context/locate_nodes/context.py` | `OK` | `22470` | `25000` |
5:10.34 INFO | `/webdriver/tests/bidi/browsing_context/locate_nodes/locator.py` | `OK` | `28679` | `25000` |
5:10.34 INFO
5:10.34 INFO ::: Running tests in a loop with restarts 10 times : FAIL
5:10.34 INFO :::
5:10.34 ERROR ::: Test verification FAIL
5:10.34 INFO :::
X connection to :99.0 broken (explicit kill or server shutdown).
[taskcluster 2023-11-28 11:12:59.875Z] === Task Finished ===
[taskcluster 2023-11-28 11:13:00.269Z] Unsuccessful task run with exit code: 1 completed in 454.193 seconds