mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-19 18:58:19 +00:00
Waiting for the state to settle after clear-all-tasks action
Bug: 313926097 Flag: N/A Test: presubmit Change-Id: Idbbf48d5814fa457b3542ff972bfb86d31f04377
This commit is contained in:
@@ -280,7 +280,6 @@ public class FallbackRecentsTest {
|
||||
|
||||
// Test dismissing all tasks.
|
||||
pressHomeAndGoToOverview().dismissAllTasks();
|
||||
waitForRecentsActivityStop(); // dismissAllTasks() will close Recents
|
||||
assertTrue("Fallback Launcher not visible", TestHelpers.wait(Until.hasObject(By.pkg(
|
||||
mOtherLauncherActivity.packageName).text(FALLBACK_LAUNCHER_TITLE)), WAIT_TIME_MS));
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
package com.android.launcher3.tapl;
|
||||
|
||||
import static com.android.launcher3.tapl.LauncherInstrumentation.TASKBAR_RES_ID;
|
||||
import static com.android.launcher3.testing.shared.TestProtocol.NORMAL_STATE_ORDINAL;
|
||||
|
||||
import android.graphics.Rect;
|
||||
|
||||
@@ -128,8 +129,19 @@ public class BaseOverview extends LauncherInstrumentation.VisibleContainer {
|
||||
flingForwardImpl();
|
||||
}
|
||||
|
||||
mLauncher.clickLauncherObject(
|
||||
mLauncher.waitForObjectInContainer(verifyActiveContainer(), clearAllSelector));
|
||||
final Runnable clickClearAll = () -> mLauncher.clickLauncherObject(
|
||||
mLauncher.waitForObjectInContainer(verifyActiveContainer(),
|
||||
clearAllSelector));
|
||||
if (mLauncher.is3PLauncher()) {
|
||||
mLauncher.executeAndWaitForLauncherStop(
|
||||
clickClearAll,
|
||||
"clicking 'Clear All'");
|
||||
} else {
|
||||
mLauncher.runToState(
|
||||
clickClearAll,
|
||||
NORMAL_STATE_ORDINAL,
|
||||
"clicking 'Clear All'");
|
||||
}
|
||||
|
||||
mLauncher.waitUntilLauncherObjectGone(clearAllSelector);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user