Merge "Revert "Make sure TAPL waits for Launcher activity to stop each time it stops"" into main

This commit is contained in:
Cliff Wang
2024-02-05 08:21:54 +00:00
committed by Android (Google) Code Review
6 changed files with 1 additions and 52 deletions

View File

@@ -599,9 +599,6 @@ public abstract class AbstractLauncherUiTest {
Wait.atMost("Launcher activity didn't stop",
() -> !launcherInstrumentation.isLauncherActivityStarted(),
DEFAULT_ACTIVITY_TIMEOUT, launcherInstrumentation);
// Reset activity stop count.
launcherInstrumentation.getAndResetActivityStopCount();
}
public static ActivityInfo resolveSystemAppInfo(String category) {

View File

@@ -44,15 +44,11 @@ public class TestIsolationRule implements TestRule {
return new Statement() {
@Override
public void evaluate() throws Throwable {
// Reset activity stop count.
mLauncher.getAndResetActivityStopCount();
base.evaluate();
// Make sure that Launcher workspace looks correct.
UiDevice.getInstance(InstrumentationRegistry.getInstrumentation()).pressHome();
AbstractLauncherUiTest.checkDetectedLeaks(mLauncher, mRequireOneActiveActivity);
mLauncher.assertNoUnexpectedStops();
}
};
}