Merge "Fix for GestureShortcutOptionControllerTest" into main

This commit is contained in:
Treehugger Robot
2024-09-24 20:19:20 +00:00
committed by Android (Google) Code Review

View File

@@ -92,6 +92,7 @@ public class GestureShortcutOptionControllerTest {
} }
@Test @Test
@DisableFlags(Flags.FLAG_A11Y_STANDALONE_GESTURE_ENABLED)
public void getSummary_touchExplorationDisabled_notInSuw_verifySummary() { public void getSummary_touchExplorationDisabled_notInSuw_verifySummary() {
enableTouchExploration(false); enableTouchExploration(false);
mController.setInSetupWizard(false); mController.setInSetupWizard(false);
@@ -106,6 +107,19 @@ public class GestureShortcutOptionControllerTest {
assertThat(mController.getSummary().toString()).isEqualTo(expected); assertThat(mController.getSummary().toString()).isEqualTo(expected);
} }
@Test
@EnableFlags(Flags.FLAG_A11Y_STANDALONE_GESTURE_ENABLED)
public void getSummary_touchExplorationDisabled_notInSuw_gestureFlag_verifySummary() {
enableTouchExploration(false);
mController.setInSetupWizard(false);
String expected = StringUtil.getIcuPluralsString(
mContext,
/* count= */ 2,
R.string.accessibility_shortcut_edit_dialog_summary_gesture);
assertThat(mController.getSummary().toString()).isEqualTo(expected);
}
@Test @Test
public void getSummary_touchExplorationDisabled_inSuw_verifySummary() { public void getSummary_touchExplorationDisabled_inSuw_verifySummary() {
enableTouchExploration(false); enableTouchExploration(false);