From 1a3724eced7d6eefb9a51b603aef7ff07ed1246c Mon Sep 17 00:00:00 2001 From: Nataniel Borges Date: Wed, 17 Mar 2021 18:36:16 +0100 Subject: [PATCH] Promote stable PIP app tests to presubmit These flaky tests have been stable for the past week and can be promoted Test: atest WMShellFlickerTests:com.android.wm.shell.flicker.pip Bug: 171049720 Bug: 167521849 Change-Id: Ibd78e9d9e53a5712ca781b265b1b65c830a74c08 --- .../wm/shell/flicker/pip/EnterPipTest.kt | 20 +------------------ .../wm/shell/flicker/pip/PipMovesInAllApps.kt | 16 ++++----------- .../wm/shell/flicker/pip/PipRotationTest.kt | 9 ++++----- .../SetRequestedOrientationWhilePinnedTest.kt | 3 +-- 4 files changed, 10 insertions(+), 38 deletions(-) diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt index 4847c98f54e96..cd20ddee04fc6 100644 --- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt +++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt @@ -16,10 +16,8 @@ package com.android.wm.shell.flicker.pip -import android.platform.test.annotations.Postsubmit import android.platform.test.annotations.Presubmit import android.view.Surface -import androidx.test.filters.FlakyTest import androidx.test.filters.RequiresDevice import com.android.server.wm.flicker.FlickerParametersRunnerFactory import com.android.server.wm.flicker.FlickerTestParameter @@ -64,7 +62,7 @@ class EnterPipTest(testSpec: FlickerTestParameter) : PipTransition(testSpec) { } } - @Postsubmit + @Presubmit @Test fun pipWindowBecomesVisible() { testSpec.assertWm { @@ -74,22 +72,6 @@ class EnterPipTest(testSpec: FlickerTestParameter) : PipTransition(testSpec) { } } - @FlakyTest(bugId = 140855415) - @Test - override fun navBarLayerIsAlwaysVisible() = super.navBarLayerIsAlwaysVisible() - - @FlakyTest(bugId = 140855415) - @Test - override fun navBarLayerRotatesAndScales() = super.navBarLayerRotatesAndScales() - - @FlakyTest(bugId = 140855415) - @Test - override fun statusBarLayerRotatesScales() = super.statusBarLayerRotatesScales() - - @FlakyTest(bugId = 140855415) - @Test - override fun noUncoveredRegions() = super.noUncoveredRegions() - companion object { @Parameterized.Parameters(name = "{0}") @JvmStatic diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipMovesInAllApps.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipMovesInAllApps.kt index d011419150e5d..f554ca344a808 100644 --- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipMovesInAllApps.kt +++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipMovesInAllApps.kt @@ -16,7 +16,7 @@ package com.android.wm.shell.flicker.pip -import android.platform.test.annotations.Postsubmit +import android.platform.test.annotations.Presubmit import android.view.Surface import androidx.test.filters.RequiresDevice import com.android.launcher3.tapl.LauncherInstrumentation @@ -55,19 +55,11 @@ class PipMovesInAllApps(testSpec: FlickerTestParameter) : PipTransition(testSpec } } - @Postsubmit - @Test - override fun statusBarWindowIsAlwaysVisible() = super.statusBarWindowIsAlwaysVisible() - - @Postsubmit - @Test - override fun navBarWindowIsAlwaysVisible() = super.navBarWindowIsAlwaysVisible() - - @Postsubmit + @Presubmit @Test fun pipAlwaysVisible() = testSpec.assertWm { this.showsAppWindow(pipApp.windowName) } - @Postsubmit + @Presubmit @Test fun pipLayerInsideDisplay() { testSpec.assertLayersStart { @@ -75,7 +67,7 @@ class PipMovesInAllApps(testSpec: FlickerTestParameter) : PipTransition(testSpec } } - @Postsubmit + @Presubmit @Test fun pipWindowMovesUp() = testSpec.assertWmEnd { val initialState = this.trace?.first()?.wmState diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipRotationTest.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipRotationTest.kt index 49a1055af4a03..8ceef8afe8570 100644 --- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipRotationTest.kt +++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/PipRotationTest.kt @@ -18,7 +18,6 @@ package com.android.wm.shell.flicker.pip import android.platform.test.annotations.Presubmit import android.view.Surface -import androidx.test.filters.FlakyTest import androidx.test.filters.RequiresDevice import com.android.server.wm.flicker.FlickerParametersRunnerFactory import com.android.server.wm.flicker.FlickerTestParameter @@ -76,19 +75,19 @@ class PipRotationTest(testSpec: FlickerTestParameter) : PipTransition(testSpec) override fun noUncoveredRegions() = testSpec.noUncoveredRegions(testSpec.config.startRotation, testSpec.config.endRotation, allStates = false) - @FlakyTest(bugId = 140855415) + @Presubmit @Test override fun navBarLayerRotatesAndScales() = testSpec.navBarLayerRotatesAndScales(testSpec.config.startRotation, testSpec.config.endRotation) - @FlakyTest(bugId = 140855415) + @Presubmit @Test override fun statusBarLayerRotatesScales() = testSpec.statusBarLayerRotatesScales(testSpec.config.startRotation, testSpec.config.endRotation) - @FlakyTest(bugId = 140855415) + @Presubmit @Test fun appLayerRotates_StartingBounds() { testSpec.assertLayersStart { @@ -97,7 +96,7 @@ class PipRotationTest(testSpec: FlickerTestParameter) : PipTransition(testSpec) } } - @FlakyTest(bugId = 140855415) + @Presubmit @Test fun appLayerRotates_EndingBounds() { testSpec.assertLayersEnd { diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/SetRequestedOrientationWhilePinnedTest.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/SetRequestedOrientationWhilePinnedTest.kt index 67e1768f3a9ff..102af92c89680 100644 --- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/SetRequestedOrientationWhilePinnedTest.kt +++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/SetRequestedOrientationWhilePinnedTest.kt @@ -16,7 +16,6 @@ package com.android.wm.shell.flicker.pip -import android.platform.test.annotations.Postsubmit import android.platform.test.annotations.Presubmit import android.view.Surface import androidx.test.filters.FlakyTest @@ -112,7 +111,7 @@ class SetRequestedOrientationWhilePinnedTest( } } - @Postsubmit + @Presubmit @Test fun pipAlwaysVisible() = testSpec.assertWm { this.showsAppWindow(pipApp.windowName)