Summary: | [WK2] layoutTestController.shadowRoot should return undefined when its argument is not an element | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Dominic Cooney <dominicc> | ||||||
Component: | Tools / Tests | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | aroben, commit-queue, dglazkov, dominicc | ||||||
Priority: | P2 | Keywords: | LayoutTestFailure, MakingBotsRed | ||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | All | ||||||||
OS: | All | ||||||||
Attachments: |
|
Description
Dominic Cooney
2011-04-08 00:25:31 PDT
Created attachment 88779 [details]
Patch
Comment on attachment 88779 [details] Patch Clearing flags on attachment: 88779 Committed r83270: <http://trac.webkit.org/changeset/83270> All reviewed patches have been landed. Closing bug. fast/dom/HTMLKeygenElement/keygen.html is still failing on WebKit2. WKBundleNodeHandleCopyElementShadowRoot is returning 0, and LayoutTestController::shadowRoot returns JSValueMakeUndefined in that case. I mean it returns JSValueMakeNull. But apparently the test wants JSValueMakeUndefined. It looks like LayoutTestController doesn't have enough information to do the right thing. It's supposed to return undefined if it is passed a non-element node, but it has no way of determining whether a particular node is an element or not. It's not clear to me that having shadowRoot return different things for non-elements and elements without shadow roots is worthwhile. Why do our tests need that behavior? The tests themselves are quite capable of figuring out what's an element and what isn't. I will work on a patch to make the ports consistent and always return null. Created attachment 88851 [details]
Patch
Comment on attachment 88851 [details] Patch Clearing flags on attachment: 88851 Committed r83333: <http://trac.webkit.org/changeset/83333> All reviewed patches have been landed. Closing bug. |