Merge "Demote 15%+ flaky tests on Raven from Presubmit"

This commit is contained in:
TreeHugger Robot
2022-10-03 14:07:49 +00:00
committed by Android (Google) Code Review
14 changed files with 127 additions and 26 deletions

View File

@@ -28,6 +28,7 @@ import com.android.server.wm.flicker.FlickerTestParameterFactory
import com.android.server.wm.flicker.annotation.Group4
import com.android.server.wm.flicker.dsl.FlickerBuilder
import com.android.server.wm.flicker.helpers.WindowUtils
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.server.wm.flicker.helpers.setRotation
import com.android.server.wm.flicker.helpers.wakeUpAndGoToHomeScreen
import com.android.server.wm.flicker.rules.RemoveAllTasksButHomeRule.Companion.removeAllTasksButHome
@@ -144,14 +145,26 @@ open class SetRequestedOrientationWhilePinnedTest(
}
}
@Presubmit
@Test
fun pipLayerInsideDisplay() {
private fun pipLayerInsideDisplay_internal() {
testSpec.assertLayersStart {
visibleRegion(pipApp).coversAtMost(startingBounds)
}
}
@Presubmit
@Test
fun pipLayerInsideDisplay() {
Assume.assumeFalse(isShellTransitionsEnabled)
pipLayerInsideDisplay_internal()
}
@FlakyTest(bugId = 250527829)
@Test
fun pipLayerInsideDisplay_shellTransit() {
Assume.assumeTrue(isShellTransitionsEnabled)
pipLayerInsideDisplay_internal()
}
@Presubmit
@Test
fun pipAlwaysVisible() {

View File

@@ -16,6 +16,7 @@
package com.android.wm.shell.flicker.splitscreen
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.IwTest
import android.platform.test.annotations.Postsubmit
import android.platform.test.annotations.Presubmit
@@ -27,6 +28,7 @@ import com.android.server.wm.flicker.FlickerTestParameterFactory
import com.android.server.wm.flicker.annotation.Group1
import com.android.server.wm.flicker.dsl.FlickerBuilder
import com.android.server.wm.flicker.helpers.WindowUtils
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.wm.shell.flicker.SPLIT_SCREEN_DIVIDER_COMPONENT
import com.android.wm.shell.flicker.appWindowBecomesInvisible
import com.android.wm.shell.flicker.appWindowIsVisibleAtEnd
@@ -35,6 +37,7 @@ import com.android.wm.shell.flicker.layerIsVisibleAtEnd
import com.android.wm.shell.flicker.splitAppLayerBoundsBecomesInvisible
import com.android.wm.shell.flicker.splitScreenDismissed
import com.android.wm.shell.flicker.splitScreenDividerBecomesInvisible
import org.junit.Assume
import org.junit.FixMethodOrder
import org.junit.Test
import org.junit.runner.RunWith
@@ -95,9 +98,7 @@ class DismissSplitScreenByDivider (testSpec: FlickerTestParameter) : SplitScreen
fun primaryAppBoundsBecomesInvisible() = testSpec.splitAppLayerBoundsBecomesInvisible(
primaryApp, landscapePosLeft = tapl.isTablet, portraitPosTop = false)
@Presubmit
@Test
fun secondaryAppBoundsIsFullscreenAtEnd() {
private fun secondaryAppBoundsIsFullscreenAtEnd_internal() {
testSpec.assertLayers {
this.isVisible(secondaryApp)
.isVisible(SPLIT_SCREEN_DIVIDER_COMPONENT)
@@ -117,6 +118,20 @@ class DismissSplitScreenByDivider (testSpec: FlickerTestParameter) : SplitScreen
}
}
@Presubmit
@Test
fun secondaryAppBoundsIsFullscreenAtEnd() {
Assume.assumeFalse(isShellTransitionsEnabled)
secondaryAppBoundsIsFullscreenAtEnd_internal()
}
@FlakyTest(bugId = 250528485)
@Test
fun secondaryAppBoundsIsFullscreenAtEnd_shellTransit() {
Assume.assumeTrue(isShellTransitionsEnabled)
secondaryAppBoundsIsFullscreenAtEnd_internal()
}
@Presubmit
@Test
fun primaryAppWindowBecomesInvisible() = testSpec.appWindowBecomesInvisible(primaryApp)

View File

@@ -92,7 +92,7 @@ class DismissSplitScreenByGoHome(
portraitPosTop = false
)
@FlakyTest(bugId = 241525302)
@FlakyTest(bugId = 250530241)
@Test
fun secondaryAppBoundsBecomesInvisible() = testSpec.splitAppLayerBoundsBecomesInvisible(
secondaryApp,

View File

@@ -16,6 +16,7 @@
package com.android.wm.shell.flicker.splitscreen
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.IwTest
import android.platform.test.annotations.Postsubmit
import android.platform.test.annotations.Presubmit
@@ -113,7 +114,7 @@ class DragDividerToResize (testSpec: FlickerTestParameter) : SplitScreenBase(tes
fun primaryAppBoundsChanges() = testSpec.splitAppLayerBoundsChanges(
primaryApp, landscapePosLeft = true, portraitPosTop = false)
@Presubmit
@FlakyTest(bugId = 250530664)
@Test
fun secondaryAppBoundsChanges() = testSpec.splitAppLayerBoundsChanges(
secondaryApp, landscapePosLeft = false, portraitPosTop = true)

View File

@@ -16,6 +16,7 @@
package com.android.wm.shell.flicker.splitscreen
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.IwTest
import android.platform.test.annotations.Postsubmit
import android.platform.test.annotations.Presubmit
@@ -25,6 +26,7 @@ import com.android.server.wm.flicker.FlickerTestParameter
import com.android.server.wm.flicker.FlickerTestParameterFactory
import com.android.server.wm.flicker.annotation.Group1
import com.android.server.wm.flicker.dsl.FlickerBuilder
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.wm.shell.flicker.appWindowBecomesVisible
import com.android.wm.shell.flicker.layerBecomesVisible
import com.android.wm.shell.flicker.layerIsVisibleAtEnd
@@ -32,6 +34,7 @@ import com.android.wm.shell.flicker.splitAppLayerBoundsBecomesVisible
import com.android.wm.shell.flicker.splitAppLayerBoundsIsVisibleAtEnd
import com.android.wm.shell.flicker.splitScreenDividerBecomesVisible
import com.android.wm.shell.flicker.splitScreenEntered
import org.junit.Assume
import org.junit.FixMethodOrder
import org.junit.Test
import org.junit.runner.RunWith
@@ -93,8 +96,19 @@ class EnterSplitScreenFromOverview(testSpec: FlickerTestParameter) : SplitScreen
@Presubmit
@Test
fun secondaryAppBoundsBecomesVisible() = testSpec.splitAppLayerBoundsBecomesVisible(
secondaryApp, landscapePosLeft = !tapl.isTablet, portraitPosTop = true)
fun secondaryAppBoundsBecomesVisible() {
Assume.assumeFalse(isShellTransitionsEnabled)
testSpec.splitAppLayerBoundsBecomesVisible(
secondaryApp, landscapePosLeft = !tapl.isTablet, portraitPosTop = true)
}
@FlakyTest(bugId = 244407465)
@Test
fun secondaryAppBoundsBecomesVisible_shellTransit() {
Assume.assumeTrue(isShellTransitionsEnabled)
testSpec.splitAppLayerBoundsBecomesVisible(
secondaryApp, landscapePosLeft = !tapl.isTablet, portraitPosTop = true)
}
@Presubmit
@Test

View File

@@ -16,7 +16,6 @@
package com.android.server.wm.flicker.activityembedding
import android.platform.test.annotations.Postsubmit
import android.platform.test.annotations.Presubmit
import android.view.Surface
import android.view.WindowManagerPolicyConstants
@@ -87,61 +86,61 @@ class OpenActivityEmbeddingPlaceholderSplit(
}
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun entireScreenCovered() = super.entireScreenCovered()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun navBarWindowIsAlwaysVisible() = super.navBarWindowIsAlwaysVisible()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun navBarLayerIsVisibleAtStartAndEnd() = super.navBarLayerIsVisibleAtStartAndEnd()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun taskBarWindowIsAlwaysVisible() = super.taskBarWindowIsAlwaysVisible()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun statusBarLayerIsVisibleAtStartAndEnd() =
super.statusBarLayerIsVisibleAtStartAndEnd()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun statusBarLayerPositionAtStartAndEnd() =
super.statusBarLayerPositionAtStartAndEnd()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun statusBarWindowIsAlwaysVisible() =
super.statusBarWindowIsAlwaysVisible()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun visibleWindowsShownMoreThanOneConsecutiveEntry() =
super.visibleWindowsShownMoreThanOneConsecutiveEntry()
/** {@inheritDoc} */
@Postsubmit
@Presubmit
@Test
override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
super.visibleLayersShownMoreThanOneConsecutiveEntry()

View File

@@ -17,7 +17,7 @@
package com.android.server.wm.flicker.close
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import androidx.test.filters.RequiresDevice
import com.android.server.wm.flicker.FlickerParametersRunnerFactory
import com.android.server.wm.flicker.FlickerTestParameter
@@ -80,7 +80,7 @@ class CloseAppBackButtonTest(testSpec: FlickerTestParameter) : CloseAppTransitio
}
/** {@inheritDoc} */
@FlakyTest(bugId = 206753786)
@Presubmit
@Test
override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()

View File

@@ -16,6 +16,7 @@
package com.android.server.wm.flicker.ime
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.view.Surface
import android.view.WindowManagerPolicyConstants
@@ -28,6 +29,8 @@ import com.android.server.wm.flicker.annotation.Group2
import com.android.server.wm.flicker.dsl.FlickerBuilder
import com.android.server.wm.flicker.helpers.ImeAppHelper
import com.android.server.wm.flicker.helpers.SimpleAppHelper
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import org.junit.Assume
import org.junit.FixMethodOrder
import org.junit.Test
import org.junit.runner.RunWith
@@ -72,6 +75,20 @@ class OpenImeWindowAndCloseTest(testSpec: FlickerTestParameter) : BaseTest(testS
@Test
fun imeLayerBecomesInvisible() = testSpec.imeLayerBecomesInvisible()
@Presubmit
@Test
override fun visibleLayersShownMoreThanOneConsecutiveEntry() {
Assume.assumeFalse(isShellTransitionsEnabled)
super.visibleLayersShownMoreThanOneConsecutiveEntry()
}
@FlakyTest(bugId = 246284124)
@Test
fun visibleLayersShownMoreThanOneConsecutiveEntry_shellTransit() {
Assume.assumeTrue(isShellTransitionsEnabled)
super.visibleLayersShownMoreThanOneConsecutiveEntry()
}
companion object {
@Parameterized.Parameters(name = "{0}")
@JvmStatic

View File

@@ -16,6 +16,7 @@
package com.android.server.wm.flicker.ime
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Postsubmit
import android.platform.test.annotations.Presubmit
import android.view.Surface
@@ -153,6 +154,7 @@ open class SwitchImeWindowsFromGestureNavTest(
override fun visibleWindowsShownMoreThanOneConsecutiveEntry() =
super.visibleWindowsShownMoreThanOneConsecutiveEntry()
@Presubmit
@Test
fun imeAppWindowVisibility() {
testSpec.assertWm {
@@ -168,6 +170,7 @@ open class SwitchImeWindowsFromGestureNavTest(
}
}
@FlakyTest(bugId = 244414110)
@Test
open fun imeLayerIsVisibleWhenSwitchingToImeApp() {
testSpec.assertLayersStart {
@@ -181,6 +184,7 @@ open class SwitchImeWindowsFromGestureNavTest(
}
}
@Presubmit
@Test
fun imeLayerIsInvisibleWhenSwitchingToTestApp() {
testSpec.assertLayersTag(TAG_IME_INVISIBLE) {

View File

@@ -16,6 +16,7 @@
package com.android.server.wm.flicker.quickswitch
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import android.view.Surface
@@ -106,7 +107,7 @@ open class QuickSwitchBetweenTwoAppsBackTest(
* Checks that the transition starts with [testApp2]'s layers filling/covering exactly the
* entirety of the display.
*/
@Presubmit
@FlakyTest(bugId = 250520840)
@Test
open fun startsWithApp2LayersCoverFullScreen() {
testSpec.assertLayersStart {
@@ -263,6 +264,10 @@ open class QuickSwitchBetweenTwoAppsBackTest(
@Test
override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()
@FlakyTest(bugId = 250518877)
@Test
override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()
companion object {
private var startDisplayBounds = Rect.EMPTY

View File

@@ -16,6 +16,7 @@
package com.android.server.wm.flicker.quickswitch
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import com.android.server.wm.flicker.FlickerParametersRunnerFactory
@@ -71,4 +72,9 @@ open class QuickSwitchBetweenTwoAppsBackTest_ShellTransit(
Assume.assumeFalse(testSpec.isTablet)
testSpec.navBarWindowIsVisibleAtStartAndEnd()
}
@FlakyTest(bugId = 246284708)
@Test
override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
super.visibleLayersShownMoreThanOneConsecutiveEntry()
}

View File

@@ -16,6 +16,7 @@
package com.android.server.wm.flicker.quickswitch
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import android.view.Surface
@@ -114,7 +115,7 @@ open class QuickSwitchBetweenTwoAppsForwardTest(
* Checks that the transition starts with [testApp1]'s layers filling/covering exactly the
* entirety of the display.
*/
@Presubmit
@FlakyTest(bugId = 250522691)
@Test
open fun startsWithApp1LayersCoverFullScreen() {
testSpec.assertLayersStart {
@@ -271,6 +272,10 @@ open class QuickSwitchBetweenTwoAppsForwardTest(
@Test
override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()
@FlakyTest(bugId = 250518877)
@Test
override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()
companion object {
private var startDisplayBounds = Rect.EMPTY

View File

@@ -16,6 +16,7 @@
package com.android.server.wm.flicker.quickswitch
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import com.android.server.wm.flicker.FlickerParametersRunnerFactory
@@ -71,4 +72,9 @@ open class QuickSwitchBetweenTwoAppsForwardTest_ShellTransit(
Assume.assumeFalse(testSpec.isTablet)
testSpec.navBarWindowIsVisibleAtStartAndEnd()
}
@FlakyTest(bugId = 246284708)
@Test
override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
super.visibleLayersShownMoreThanOneConsecutiveEntry()
}

View File

@@ -16,6 +16,7 @@
package com.android.server.wm.flicker.quickswitch
import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import android.view.Surface
@@ -27,6 +28,7 @@ import com.android.server.wm.flicker.FlickerTestParameterFactory
import com.android.server.wm.flicker.annotation.Group1
import com.android.server.wm.flicker.dsl.FlickerBuilder
import com.android.server.wm.flicker.helpers.SimpleAppHelper
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.server.wm.flicker.navBarWindowIsVisibleAtStartAndEnd
import com.android.server.wm.traces.common.ComponentNameMatcher
import com.android.server.wm.traces.common.Rect
@@ -294,6 +296,20 @@ class QuickSwitchFromLauncherTest(testSpec: FlickerTestParameter) : BaseTest(tes
testSpec.navBarWindowIsVisibleAtStartAndEnd()
}
@Presubmit
@Test
override fun visibleLayersShownMoreThanOneConsecutiveEntry() {
Assume.assumeFalse(isShellTransitionsEnabled)
super.visibleLayersShownMoreThanOneConsecutiveEntry()
}
@FlakyTest(bugId = 246285528)
@Test
fun visibleLayersShownMoreThanOneConsecutiveEntry_shellTransit() {
Assume.assumeTrue(isShellTransitionsEnabled)
super.visibleLayersShownMoreThanOneConsecutiveEntry()
}
companion object {
/** {@inheritDoc} */
private var startDisplayBounds = Rect.EMPTY