Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b297c7e6 authored by Alex Chau's avatar Alex Chau
Browse files

Add screen record for failing TaplTestsQuickstep

- For debugging failures that only happnes on cuttlefish

Bug: 191344757
Test: TaplTestsQuickstep
Change-Id: Iac16e222dc7b60f94e1eb7f305c5ccb909161783
parent efa5e9f5
Loading
Loading
Loading
Loading
+6 −2
Original line number Original line Diff line number Diff line
@@ -23,7 +23,6 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.assertTrue;


import android.content.Intent;
import android.content.Intent;
import android.util.Log;


import androidx.test.filters.LargeTest;
import androidx.test.filters.LargeTest;
import androidx.test.runner.AndroidJUnit4;
import androidx.test.runner.AndroidJUnit4;
@@ -37,8 +36,8 @@ import com.android.launcher3.tapl.LauncherInstrumentation.NavigationModel;
import com.android.launcher3.tapl.Overview;
import com.android.launcher3.tapl.Overview;
import com.android.launcher3.tapl.OverviewActions;
import com.android.launcher3.tapl.OverviewActions;
import com.android.launcher3.tapl.OverviewTask;
import com.android.launcher3.tapl.OverviewTask;
import com.android.launcher3.testing.TestProtocol;
import com.android.launcher3.ui.TaplTestsLauncher3;
import com.android.launcher3.ui.TaplTestsLauncher3;
import com.android.launcher3.util.rule.ScreenRecordRule.ScreenRecord;
import com.android.quickstep.NavigationModeSwitchRule.NavigationModeSwitch;
import com.android.quickstep.NavigationModeSwitchRule.NavigationModeSwitch;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.RecentsView;


@@ -94,6 +93,7 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {


    @Test
    @Test
    @PortraitLandscape
    @PortraitLandscape
    @ScreenRecord //b/191344757
    public void testOverview() throws Exception {
    public void testOverview() throws Exception {
        startTestAppsWithCheck();
        startTestAppsWithCheck();
        // mLauncher.pressHome() also tests an important case of pressing home while in background.
        // mLauncher.pressHome() also tests an important case of pressing home while in background.
@@ -163,6 +163,7 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {
    @Test
    @Test
    @NavigationModeSwitch
    @NavigationModeSwitch
    @PortraitLandscape
    @PortraitLandscape
    @ScreenRecord //b/191344757
    public void testOverviewActions() throws Exception {
    public void testOverviewActions() throws Exception {
        // Experimenting for b/165029151:
        // Experimenting for b/165029151:
        final Overview overview = mLauncher.pressHome().switchToOverview();
        final Overview overview = mLauncher.pressHome().switchToOverview();
@@ -188,6 +189,7 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {
    @Test
    @Test
    @NavigationModeSwitch
    @NavigationModeSwitch
    @PortraitLandscape
    @PortraitLandscape
    @ScreenRecord //b/191344757
    public void testSwitchToOverview() throws Exception {
    public void testSwitchToOverview() throws Exception {
        assertNotNull("Workspace.switchToOverview() returned null",
        assertNotNull("Workspace.switchToOverview() returned null",
                mLauncher.pressHome().switchToOverview());
                mLauncher.pressHome().switchToOverview());
@@ -198,6 +200,7 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {
    @Test
    @Test
    @NavigationModeSwitch
    @NavigationModeSwitch
    @PortraitLandscape
    @PortraitLandscape
    @ScreenRecord //b/191344757
    public void testBackground() throws Exception {
    public void testBackground() throws Exception {
        startAppFast(resolveSystemApp(Intent.CATEGORY_APP_CALCULATOR));
        startAppFast(resolveSystemApp(Intent.CATEGORY_APP_CALCULATOR));
        final Background background = getAndAssertBackground();
        final Background background = getAndAssertBackground();
@@ -219,6 +222,7 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {


    @Test
    @Test
    @PortraitLandscape
    @PortraitLandscape
    @ScreenRecord //b/191344757
    public void testAllAppsFromHome() throws Exception {
    public void testAllAppsFromHome() throws Exception {
        // Test opening all apps
        // Test opening all apps
        assertNotNull("switchToAllApps() returned null",
        assertNotNull("switchToAllApps() returned null",