From c2441dffbeff787937739da7e828b696592b86b8 Mon Sep 17 00:00:00 2001 From: Alex Chau Date: Wed, 11 Aug 2021 17:07:50 +0100 Subject: [PATCH] Even further increase FORCE_PAUSE_TIMEOUT in tests - http://b//194114179#comment17 shows that 900ms should work for most cases Bug: 194114179 Test: atest NexusLauncherOutOfProcTests:com.android.launcher3.memory.MemoryTests#testAppLaunchFromWorkspace Change-Id: Ie2832d7ad25b0844121ecf626903140bfeedc5ba --- .../com/android/launcher3/tapl/LauncherInstrumentation.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java b/tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java index ded4282b9b..8b9ae6964c 100644 --- a/tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java +++ b/tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java @@ -80,6 +80,7 @@ import java.util.Collections; import java.util.Deque; import java.util.LinkedList; import java.util.List; +import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeoutException; import java.util.function.Consumer; import java.util.function.Function; @@ -96,7 +97,7 @@ public final class LauncherInstrumentation { private static final String TAG = "Tapl"; private static final int ZERO_BUTTON_STEPS_FROM_BACKGROUND_TO_HOME = 20; private static final int GESTURE_STEP_MS = 16; - private static final long FORCE_PAUSE_TIMEOUT_MS = 700; + private static final long FORCE_PAUSE_TIMEOUT_MS = TimeUnit.SECONDS.toMillis(2); static final Pattern EVENT_TOUCH_DOWN = getTouchEventPattern("ACTION_DOWN"); static final Pattern EVENT_TOUCH_UP = getTouchEventPattern("ACTION_UP");