Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -437,6 +437,7 @@ public open class ReactAccessibilityDelegate( // The View this delegate is attac
SPINBUTTON,
SWITCH,
TAB,
TABBAR,
TABLIST,
TIMER,
LIST,
Expand Down Expand Up @@ -491,6 +492,7 @@ public open class ReactAccessibilityDelegate( // The View this delegate is attac
RADIOGROUP,
SCROLLBAR,
TAB,
TABBAR,
TABLIST,
TIMER,
TOOLBAR -> "android.view.View"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -347,6 +347,15 @@ class ReactAccessibilityDelegateTest {
assertThat(view.getTag(R.id.accessibility_state_expanded)).isEqualTo(true)
}

@Test
fun testAccessibilityRole_fromValue_tabbar_resolvesInsteadOfThrowing() {
val role = ReactAccessibilityDelegate.AccessibilityRole.fromValue("tabbar")

assertThat(role).isEqualTo(ReactAccessibilityDelegate.AccessibilityRole.TABBAR)
assertThat(ReactAccessibilityDelegate.AccessibilityRole.getValue(role))
.isEqualTo("android.view.View")
}

@Test
fun testPerformAccessibilityAction_collapseAction_fromAccessibilityActions() {
val accessibilityActions = JavaOnlyArray()
Expand Down
Loading