relax all accessibility action check on android accessibility integra… (#99525)
* relax all accessibility action check on android accessibility integration test * update
This commit is contained in:
parent
7bd067ab24
commit
dc928989f4
@ -40,10 +40,6 @@ void main() {
|
|||||||
// The version of TalkBack running on the device.
|
// The version of TalkBack running on the device.
|
||||||
Version talkbackVersion;
|
Version talkbackVersion;
|
||||||
|
|
||||||
// The version of TalkBack where the actions on the first item were fixed.
|
|
||||||
final Version fixedTalkback = Version(9, 1, 0);
|
|
||||||
|
|
||||||
|
|
||||||
Future<Version> getTalkbackVersion() async {
|
Future<Version> getTalkbackVersion() async {
|
||||||
final io.ProcessResult result = await io.Process.run(adbPath(), const <String>[
|
final io.ProcessResult result = await io.Process.run(adbPath(), const <String>[
|
||||||
'shell',
|
'shell',
|
||||||
@ -314,8 +310,8 @@ void main() {
|
|||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -331,8 +327,8 @@ void main() {
|
|||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -343,9 +339,8 @@ void main() {
|
|||||||
className: AndroidClassName.checkBox,
|
className: AndroidClassName.checkBox,
|
||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isEnabled: false,
|
isEnabled: false,
|
||||||
actions: const <AndroidSemanticsAction>[
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
actions: const <AndroidSemanticsAction>[],
|
||||||
],
|
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}, timeout: Timeout.none);
|
}, timeout: Timeout.none);
|
||||||
@ -361,8 +356,8 @@ void main() {
|
|||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -378,8 +373,8 @@ void main() {
|
|||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -397,8 +392,8 @@ void main() {
|
|||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -414,8 +409,8 @@ void main() {
|
|||||||
isCheckable: true,
|
isCheckable: true,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -436,8 +431,8 @@ void main() {
|
|||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
contentDescription: switchLabel,
|
contentDescription: switchLabel,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -463,8 +458,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -485,9 +480,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
if (item == popupItems.first) AndroidSemanticsAction.clearAccessibilityFocus,
|
|
||||||
if (item != popupItems.first) AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -509,10 +503,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
if (talkbackVersion < fixedTalkback && item == popupItems.first) AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
if (talkbackVersion >= fixedTalkback && item == popupItems.first) AndroidSemanticsAction.clearAccessibilityFocus,
|
|
||||||
if (item != popupItems.first) AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -532,8 +524,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -557,10 +549,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
if (talkbackVersion < fixedTalkback && item == popupItems.first) AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
if (talkbackVersion >= fixedTalkback && item == popupItems.first) AndroidSemanticsAction.clearAccessibilityFocus,
|
|
||||||
if (item != popupItems.first) AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -592,10 +582,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
if (talkbackVersion < fixedTalkback && item == popupItems.first) AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
if (talkbackVersion >= fixedTalkback && item == popupItems.first) AndroidSemanticsAction.clearAccessibilityFocus,
|
|
||||||
if (item != popupItems.first) AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -620,8 +608,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -639,8 +627,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -655,10 +643,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
actions: <AndroidSemanticsAction>[
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
if (item == 'Title') AndroidSemanticsAction.clearAccessibilityFocus,
|
actions: <AndroidSemanticsAction>[],
|
||||||
if (item != 'Title') AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
reason: "Alert $item button doesn't have the right semantics");
|
reason: "Alert $item button doesn't have the right semantics");
|
||||||
}
|
}
|
||||||
@ -678,8 +664,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
actions: <AndroidSemanticsAction>[
|
actions: <AndroidSemanticsAction>[
|
||||||
AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
AndroidSemanticsAction.click,
|
AndroidSemanticsAction.click,
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
@ -694,11 +680,8 @@ void main() {
|
|||||||
isCheckable: false,
|
isCheckable: false,
|
||||||
isEnabled: true,
|
isEnabled: true,
|
||||||
isFocusable: true,
|
isFocusable: true,
|
||||||
actions: <AndroidSemanticsAction>[
|
ignoredActions: ignoredAccessibilityFocusActions,
|
||||||
if (talkbackVersion < fixedTalkback && item == 'Title') AndroidSemanticsAction.accessibilityFocus,
|
actions: <AndroidSemanticsAction>[],
|
||||||
if (talkbackVersion >= fixedTalkback && item == 'Title') AndroidSemanticsAction.clearAccessibilityFocus,
|
|
||||||
if (item != 'Title') AndroidSemanticsAction.accessibilityFocus,
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
reason: "Alert $item button doesn't have the right semantics");
|
reason: "Alert $item button doesn't have the right semantics");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user