| Summary: | [WebDriver] Add support for shadow roots | ||||||
|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Carlos Garcia Campos <cgarcia> | ||||
| Component: | WebDriver | Assignee: | Nobody <webkit-unassigned> | ||||
| Status: | RESOLVED FIXED | ||||||
| Severity: | Normal | CC: | aperez, bburg, webkit-bug-importer | ||||
| Priority: | P2 | Keywords: | InRadar | ||||
| Version: | WebKit Nightly Build | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| See Also: | https://bugs.webkit.org/show_bug.cgi?id=230551 | ||||||
| Attachments: |
|
||||||
|
Description
Carlos Garcia Campos
2021-09-22 05:35:46 PDT
Created attachment 450514 [details]
Patch
Comment on attachment 450514 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=450514&action=review > Source/WebDriver/Session.cpp:1139 > + if (isShadowRoot == ElementIsShadowRoot::Yes && result.errorString() == "stale element reference") { Wouldn't it be more robust to compare the error code instead of comparing strings? As in: result.errorCode == CommandResult::ErrorCode::StaleElementReference > Source/WebDriver/WebDriverService.cpp:1461 > } These two functions are so similar... the only variation AFAICS is using FindElementsMode::{Multiple,Single} in the last line; maybe most of the function body could be factored out? Committed r289202 (?): <https://commits.webkit.org/r289202> |