mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Improve some webdriver conformance tests results (#36673)
These changes allow test_dom_token_list from /execute_script/collections.py to pass, and various tests in /execute_script/arguments.py to expose new failures. Testing: Not run in CI yet, but verified results from tests/wpt/tests/webdriver/tests/classic/{execute_script,execute_async_script} locally. Fixes: #35738 --------- Signed-off-by: Josh Matthews <josh@joshmatthews.net>
This commit is contained in:
parent
a18c6e2c78
commit
f47e69c112
28 changed files with 128 additions and 165 deletions
|
@ -532,7 +532,7 @@ where
|
|||
|
||||
/// Returns whether `value` is an array-like object (Array, FileList,
|
||||
/// HTMLCollection, HTMLFormControlsCollection, HTMLOptionsCollection,
|
||||
/// NodeList).
|
||||
/// NodeList, DOMTokenList).
|
||||
///
|
||||
/// # Safety
|
||||
/// `cx` must point to a valid, non-null JSContext.
|
||||
|
@ -548,6 +548,10 @@ pub unsafe fn is_array_like<D: crate::DomTypes>(cx: *mut JSContext, value: Handl
|
|||
_ => return false,
|
||||
};
|
||||
|
||||
// TODO: HTMLAllCollection
|
||||
if root_from_object::<D::DOMTokenList>(object, cx).is_ok() {
|
||||
return true;
|
||||
}
|
||||
if root_from_object::<D::FileList>(object, cx).is_ok() {
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -150,6 +150,10 @@ partial interface Window {
|
|||
undefined webdriverCallback(optional any result);
|
||||
undefined webdriverException(optional any result);
|
||||
undefined webdriverTimeout();
|
||||
Element? webdriverElement(DOMString id);
|
||||
Element? webdriverFrame(DOMString id);
|
||||
Window? webdriverWindow(DOMString id);
|
||||
ShadowRoot? webdriverShadowRoot(DOMString id);
|
||||
};
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-sessionstorage
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue