This corresponds to the following `DOM.AccessibilityProperties` properties (except they'd return `Node`s instead of `DOM.NodeId`s): - activeDescendantNodeId - childNodeIds - controlledNodeIds - flowedNodeIds - mouseEventNodeId - ownedNodeIds - parentNodeId - selectedChildNodeIds
<rdar://problem/46799956>
Created attachment 358565 [details] Patch
Created attachment 358568 [details] Patch Minor test fixes.
Created attachment 358848 [details] Patch Throw an error when called outside of a test
Created attachment 358858 [details] Patch
Comment on attachment 358858 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=358858&action=review r=me, earlier patch comments applying. > Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp:109 > + if (controlledElement) Nit: Is this if check necessary, would elementsFromAttribute return a null element? > Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp:131 > + if (flowedElement) Nit: Is this if check necessary, would elementsFromAttribute return a null element? > Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp:148 > + } > + return nullptr; Style: Sometimes you don't have a newline before the final return and sometimes you do. Would be nice to be consistent. I'd vote for always having a newline after a closing brace before a final return. > Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp:164 > + if (ownedElement) Nit: Is this if check necessary, would elementsFromAttribute return a null element?
Comment on attachment 358858 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=358858&action=review >> Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp:109 >> + if (controlledElement) > > Nit: Is this if check necessary, would elementsFromAttribute return a null element? It doesn't look like it, as `elementsFromAttribute` does its own check, but I think this isn't a bad thing to have.
Created attachment 359174 [details] Patch
Created attachment 359175 [details] Patch
(In reply to Devin Rousso from comment #7) > Comment on attachment 358858 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=358858&action=review > > >> Source/WebCore/inspector/InspectorAuditAccessibilityUtilities.cpp:109 > >> + if (controlledElement) > > > > Nit: Is this if check necessary, would elementsFromAttribute return a null element? > > It doesn't look like it, as `elementsFromAttribute` does its own check, but > I think this isn't a bad thing to have. We should never have to write code like: if (auto* x : list) { if (x) ...; } Lets drop them. The originating code in DOMAgent doesn't have these checks.
Comment on attachment 359175 [details] Patch Attachment 359175 [details] did not pass mac-ews (mac): Output: https://webkit-queues.webkit.org/results/10761241 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359182 [details] Archive of layout-test-results from ews100 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews100 Port: mac-highsierra Platform: Mac OS X 10.13.6
Comment on attachment 359175 [details] Patch Attachment 359175 [details] did not pass mac-wk2-ews (mac-wk2): Output: https://webkit-queues.webkit.org/results/10761272 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359183 [details] Archive of layout-test-results from ews105 for mac-highsierra-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews105 Port: mac-highsierra-wk2 Platform: Mac OS X 10.13.6
Comment on attachment 359175 [details] Patch Attachment 359175 [details] did not pass mac-debug-ews (mac): Output: https://webkit-queues.webkit.org/results/10761253 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359188 [details] Archive of layout-test-results from ews112 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews112 Port: mac-highsierra Platform: Mac OS X 10.13.6
Created attachment 359232 [details] Patch
Comment on attachment 359232 [details] Patch Attachment 359232 [details] did not pass mac-ews (mac): Output: https://webkit-queues.webkit.org/results/10766072 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359237 [details] Archive of layout-test-results from ews100 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews100 Port: mac-highsierra Platform: Mac OS X 10.13.6
Comment on attachment 359232 [details] Patch Attachment 359232 [details] did not pass mac-wk2-ews (mac-wk2): Output: https://webkit-queues.webkit.org/results/10766572 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359240 [details] Archive of layout-test-results from ews107 for mac-highsierra-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews107 Port: mac-highsierra-wk2 Platform: Mac OS X 10.13.6
Comment on attachment 359232 [details] Patch Attachment 359232 [details] did not pass mac-debug-ews (mac): Output: https://webkit-queues.webkit.org/results/10766525 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359244 [details] Archive of layout-test-results from ews114 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews114 Port: mac-highsierra Platform: Mac OS X 10.13.6
Created attachment 359562 [details] Patch Rebase
Comment on attachment 359562 [details] Patch Attachment 359562 [details] did not pass mac-ews (mac): Output: https://webkit-queues.webkit.org/results/10804235 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359567 [details] Archive of layout-test-results from ews103 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews103 Port: mac-highsierra Platform: Mac OS X 10.13.6
Comment on attachment 359562 [details] Patch Attachment 359562 [details] did not pass mac-debug-ews (mac): Output: https://webkit-queues.webkit.org/results/10804354 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359572 [details] Archive of layout-test-results from ews114 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews114 Port: mac-highsierra Platform: Mac OS X 10.13.6
Comment on attachment 359562 [details] Patch Attachment 359562 [details] did not pass mac-wk2-ews (mac-wk2): Output: https://webkit-queues.webkit.org/results/10805257 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359581 [details] Archive of layout-test-results from ews107 for mac-highsierra-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews107 Port: mac-highsierra-wk2 Platform: Mac OS X 10.13.6
Created attachment 359596 [details] Patch
Comment on attachment 359596 [details] Patch Attachment 359596 [details] did not pass mac-ews (mac): Output: https://webkit-queues.webkit.org/results/10808577 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359601 [details] Archive of layout-test-results from ews103 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews103 Port: mac-highsierra Platform: Mac OS X 10.13.6
Comment on attachment 359596 [details] Patch Attachment 359596 [details] did not pass mac-wk2-ews (mac-wk2): Output: https://webkit-queues.webkit.org/results/10808595 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359602 [details] Archive of layout-test-results from ews105 for mac-highsierra-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews105 Port: mac-highsierra-wk2 Platform: Mac OS X 10.13.6
Comment on attachment 359596 [details] Patch Attachment 359596 [details] did not pass mac-debug-ews (mac): Output: https://webkit-queues.webkit.org/results/10809640 New failing tests: inspector/audit/run-accessibility.html
Created attachment 359604 [details] Archive of layout-test-results from ews117 for mac-highsierra The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews117 Port: mac-highsierra Platform: Mac OS X 10.13.6
Created attachment 359749 [details] Patch
Comment on attachment 359749 [details] Patch Clearing flags on attachment: 359749 Committed r240277: <https://trac.webkit.org/changeset/240277>
All reviewed patches have been landed. Closing bug.