diff options
author | 2025-03-21 16:59:15 +0000 | |
---|---|---|
committer | 2025-03-24 11:15:24 +0000 | |
commit | fc3cc7bf5665efd282897de045ae68149d0fe8e3 (patch) | |
tree | 41e0381e8e38dc0e7caf3c6e9742fa87c6e8d45b /libs | |
parent | 57e0889e58e3edc1bd7ec16ecd46de8c5fbf4066 (diff) |
Use calculator instead of Gmail in UnminimizeAppFromTaskbar
When launching GMail we expect to open the Activity
ConversationListActivityGmail, but gmail might enter another Activity
before that if for example the test device has no logged-in account.
Instead use the calculator that doesn't have log-in screen.
Bug: 399420941
Test: atest PlatformScenarioTests:UnminimizeAppFromTaskbarTest
Flag: EXEMPT - test fix
Change-Id: I7c24d552ad19ba662db950f1bd9596eb4f270760
Diffstat (limited to 'libs')
-rw-r--r-- | libs/WindowManager/Shell/tests/e2e/desktopmode/scenarios/src/com/android/wm/shell/scenarios/UnminimizeAppFromTaskbar.kt | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/libs/WindowManager/Shell/tests/e2e/desktopmode/scenarios/src/com/android/wm/shell/scenarios/UnminimizeAppFromTaskbar.kt b/libs/WindowManager/Shell/tests/e2e/desktopmode/scenarios/src/com/android/wm/shell/scenarios/UnminimizeAppFromTaskbar.kt index 7d9f2bf8fdf6..05ddb4043b82 100644 --- a/libs/WindowManager/Shell/tests/e2e/desktopmode/scenarios/src/com/android/wm/shell/scenarios/UnminimizeAppFromTaskbar.kt +++ b/libs/WindowManager/Shell/tests/e2e/desktopmode/scenarios/src/com/android/wm/shell/scenarios/UnminimizeAppFromTaskbar.kt @@ -19,7 +19,7 @@ package com.android.wm.shell.scenarios import android.app.Instrumentation import android.tools.NavBar import android.tools.Rotation -import android.tools.device.apphelpers.GmailAppHelper +import android.tools.device.apphelpers.CalculatorAppHelper import android.tools.flicker.rules.ChangeDisplayOrientationRule import android.tools.traces.parsers.WindowManagerStateHelper import androidx.test.platform.app.InstrumentationRegistry @@ -44,8 +44,9 @@ abstract class UnminimizeAppFromTaskbar(val rotation: Rotation = Rotation.ROTATI private val wmHelper = WindowManagerStateHelper(instrumentation) private val device = UiDevice.getInstance(instrumentation) private val testApp = DesktopModeAppHelper(SimpleAppHelper(instrumentation)) - private val gmailHelper = GmailAppHelper(instrumentation) - private val gmailApp = DesktopModeAppHelper(gmailHelper) + private val calculatorHelper = CalculatorAppHelper(instrumentation) + private val calculatorApp = DesktopModeAppHelper(calculatorHelper) + @Rule @JvmField val testSetupRule = Utils.testSetupRule(NavBar.MODE_GESTURAL, rotation) @@ -59,20 +60,20 @@ abstract class UnminimizeAppFromTaskbar(val rotation: Rotation = Rotation.ROTATI ChangeDisplayOrientationRule.setRotation(rotation) testApp.enterDesktopMode(wmHelper, device) tapl.showTaskbarIfHidden() - gmailApp.launchViaIntent(wmHelper) - gmailApp.minimizeDesktopApp(wmHelper, device) + calculatorApp.launchViaIntent(wmHelper) + calculatorApp.minimizeDesktopApp(wmHelper, device) } @Test open fun unminimizeApp() { tapl.launchedAppState.taskbar - .getAppIcon(gmailHelper.appName) - .launch(gmailHelper.packageName) + .getAppIcon(calculatorHelper.appName) + .launch(calculatorApp.packageName) } @After fun teardown() { testApp.exit(wmHelper) - gmailApp.exit(wmHelper) + calculatorApp.exit(wmHelper) } -}
\ No newline at end of file +} |