haikuwebkit/LayoutTests/accessibility/presentation-role-iframe-ex...

19 lines
451 B
Plaintext
Raw Permalink Normal View History

AX: role="none" (or presentation) does not work on iframes https://bugs.webkit.org/show_bug.cgi?id=173930 <rdar://problem/33034347> Reviewed by Ryosuke Niwa. Source/WebCore: Support setting a presentational role on an iframe so that the AXWebArea disappears from the hierarchy. Accomplish this by adding children for attachment and scroll view elements the way other children are added. That is, only add the non-ignored children directly (which means move the addChild logic into AccessibilityObject.) Test: accessibility/presentation-role-iframe.html * accessibility/AccessibilityNodeObject.cpp: (WebCore::AccessibilityNodeObject::AccessibilityNodeObject): (WebCore::AccessibilityNodeObject::insertChild): Deleted. (WebCore::AccessibilityNodeObject::addChild): Deleted. * accessibility/AccessibilityNodeObject.h: * accessibility/AccessibilityObject.cpp: (WebCore::AccessibilityObject::AccessibilityObject): (WebCore::AccessibilityObject::insertChild): (WebCore::AccessibilityObject::addChild): (WebCore::nodeHasPresentationRole): * accessibility/AccessibilityObject.h: (WebCore::AccessibilityObject::addChild): Deleted. (WebCore::AccessibilityObject::insertChild): Deleted. * accessibility/AccessibilityRenderObject.cpp: (WebCore::webAreaIsPresentational): (WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored): (WebCore::AccessibilityRenderObject::addAttachmentChildren): * accessibility/AccessibilityScrollView.cpp: (WebCore::AccessibilityScrollView::addChildren): LayoutTests: * accessibility/presentation-role-iframe-expected.txt: Added. * accessibility/presentation-role-iframe.html: Added. Canonical link: https://commits.webkit.org/190928@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@219075 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-07-03 17:18:34 +00:00
This tests that setting role=presentation on an iframe/object hides the AXWebArea.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
1. Content child: AXRole: AXGroup
1. Content grand child: AXRole: AXButton
2. Content child: AXRole: AXScrollArea
2. Content grand child: AXRole: AXWebArea
3. Content child: AXRole: AXGroup
3. Content grand child: AXRole: AXButton
PASS successfullyParsed is true
TEST COMPLETE