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

Commit 8bdd9e9c authored by Nataniel Borges's avatar Nataniel Borges
Browse files

Promote passing quick switch tests

QuickSwitchBetweenTwoAppsForwardTest and
QuickSwitchBetweenTwoAppsBackTest

Bug: 250520840
Bug: 250522691
Bug: 250518877
Test: atest FlickerTests:QuickSwitchBetweenTwoAppsForwardTest QuickSwitchBetweenTwoAppsBackTest
Change-Id: Icfca17347c2554f257e3b2558f6ed5b7b4860bd3
parent 4d05eedd
Loading
Loading
Loading
Loading
+1 −11
Original line number Original line Diff line number Diff line
@@ -16,7 +16,6 @@


package com.android.server.wm.flicker.quickswitch
package com.android.server.wm.flicker.quickswitch


import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import android.platform.test.annotations.RequiresDevice
import android.view.Surface
import android.view.Surface
@@ -104,7 +103,7 @@ open class QuickSwitchBetweenTwoAppsBackTest(testSpec: FlickerTestParameter) : B
     * Checks that the transition starts with [testApp2]'s layers filling/covering exactly the
     * Checks that the transition starts with [testApp2]'s layers filling/covering exactly the
     * entirety of the display.
     * entirety of the display.
     */
     */
    @FlakyTest(bugId = 250520840)
    @Presubmit
    @Test
    @Test
    open fun startsWithApp2LayersCoverFullScreen() {
    open fun startsWithApp2LayersCoverFullScreen() {
        testSpec.assertLayersStart {
        testSpec.assertLayersStart {
@@ -236,15 +235,6 @@ open class QuickSwitchBetweenTwoAppsBackTest(testSpec: FlickerTestParameter) : B
        }
        }
    }
    }


    /** {@inheritDoc} */
    @Presubmit
    @Test
    override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()

    @FlakyTest(bugId = 250518877)
    @Test
    override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()

    companion object {
    companion object {
        private var startDisplayBounds = Rect.EMPTY
        private var startDisplayBounds = Rect.EMPTY


+13 −2
Original line number Original line Diff line number Diff line
@@ -23,6 +23,7 @@ import com.android.server.wm.flicker.FlickerParametersRunnerFactory
import com.android.server.wm.flicker.FlickerTestParameter
import com.android.server.wm.flicker.FlickerTestParameter
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.server.wm.flicker.navBarWindowIsVisibleAtStartAndEnd
import com.android.server.wm.flicker.navBarWindowIsVisibleAtStartAndEnd
import com.android.server.wm.traces.common.ComponentNameMatcher
import org.junit.Assume
import org.junit.Assume
import org.junit.Before
import org.junit.Before
import org.junit.FixMethodOrder
import org.junit.FixMethodOrder
@@ -61,8 +62,8 @@ open class QuickSwitchBetweenTwoAppsBackTest_ShellTransit(testSpec: FlickerTestP
    override fun navBarWindowIsAlwaysVisible() = super.navBarWindowIsAlwaysVisible()
    override fun navBarWindowIsAlwaysVisible() = super.navBarWindowIsAlwaysVisible()


    /**
    /**
     * Checks that [ComponentMatcher.NAV_BAR] window is visible and above the app windows at the
     * Checks that [ComponentNameMatcher.NAV_BAR] window is visible and above the app windows at
     * start and end of the WM trace
     * the start and end of the WM trace
     */
     */
    @Presubmit
    @Presubmit
    @Test
    @Test
@@ -71,8 +72,18 @@ open class QuickSwitchBetweenTwoAppsBackTest_ShellTransit(testSpec: FlickerTestP
        testSpec.navBarWindowIsVisibleAtStartAndEnd()
        testSpec.navBarWindowIsVisibleAtStartAndEnd()
    }
    }


    /** {@inheritDoc} */
    @FlakyTest(bugId = 250520840)
    @Test
    override fun startsWithApp2LayersCoverFullScreen() =
        super.startsWithApp2LayersCoverFullScreen()

    @FlakyTest(bugId = 246284708)
    @FlakyTest(bugId = 246284708)
    @Test
    @Test
    override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
    override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
        super.visibleLayersShownMoreThanOneConsecutiveEntry()
        super.visibleLayersShownMoreThanOneConsecutiveEntry()

    @FlakyTest(bugId = 250518877)
    @Test
    override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()
}
}
+1 −6
Original line number Original line Diff line number Diff line
@@ -16,7 +16,6 @@


package com.android.server.wm.flicker.quickswitch
package com.android.server.wm.flicker.quickswitch


import android.platform.test.annotations.FlakyTest
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import android.platform.test.annotations.RequiresDevice
import android.view.Surface
import android.view.Surface
@@ -116,7 +115,7 @@ open class QuickSwitchBetweenTwoAppsForwardTest(testSpec: FlickerTestParameter)
     * Checks that the transition starts with [testApp1]'s layers filling/covering exactly the
     * Checks that the transition starts with [testApp1]'s layers filling/covering exactly the
     * entirety of the display.
     * entirety of the display.
     */
     */
    @FlakyTest(bugId = 250522691)
    @Presubmit
    @Test
    @Test
    open fun startsWithApp1LayersCoverFullScreen() {
    open fun startsWithApp1LayersCoverFullScreen() {
        testSpec.assertLayersStart {
        testSpec.assertLayersStart {
@@ -255,10 +254,6 @@ open class QuickSwitchBetweenTwoAppsForwardTest(testSpec: FlickerTestParameter)
    @Test
    @Test
    override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()
    override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()


    @FlakyTest(bugId = 250518877)
    @Test
    override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()

    companion object {
    companion object {
        private var startDisplayBounds = Rect.EMPTY
        private var startDisplayBounds = Rect.EMPTY


+12 −2
Original line number Original line Diff line number Diff line
@@ -23,6 +23,7 @@ import com.android.server.wm.flicker.FlickerParametersRunnerFactory
import com.android.server.wm.flicker.FlickerTestParameter
import com.android.server.wm.flicker.FlickerTestParameter
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.server.wm.flicker.navBarWindowIsVisibleAtStartAndEnd
import com.android.server.wm.flicker.navBarWindowIsVisibleAtStartAndEnd
import com.android.server.wm.traces.common.ComponentNameMatcher
import org.junit.Assume
import org.junit.Assume
import org.junit.Before
import org.junit.Before
import org.junit.FixMethodOrder
import org.junit.FixMethodOrder
@@ -62,8 +63,8 @@ open class QuickSwitchBetweenTwoAppsForwardTest_ShellTransit(testSpec: FlickerTe
    override fun navBarWindowIsAlwaysVisible() = super.navBarWindowIsAlwaysVisible()
    override fun navBarWindowIsAlwaysVisible() = super.navBarWindowIsAlwaysVisible()


    /**
    /**
     * Checks that [ComponentMatcher.NAV_BAR] window is visible and above the app windows at the
     * Checks that [ComponentNameMatcher.NAV_BAR] window is visible and above the app windows at
     * start and end of the WM trace
     * the start and end of the WM trace
     */
     */
    @Presubmit
    @Presubmit
    @Test
    @Test
@@ -76,4 +77,13 @@ open class QuickSwitchBetweenTwoAppsForwardTest_ShellTransit(testSpec: FlickerTe
    @Test
    @Test
    override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
    override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
        super.visibleLayersShownMoreThanOneConsecutiveEntry()
        super.visibleLayersShownMoreThanOneConsecutiveEntry()

    @FlakyTest(bugId = 250518877)
    @Test
    override fun navBarLayerPositionAtStartAndEnd() = super.navBarLayerPositionAtStartAndEnd()

    @FlakyTest(bugId = 250522691)
    @Test
    override fun startsWithApp1LayersCoverFullScreen() =
        super.startsWithApp1LayersCoverFullScreen()
}
}