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

Commit 77928c86 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Promote passing IME flicker tests"

parents 240763b8 ba9f1e4a
Loading
Loading
Loading
Loading
+9 −29
Original line number Diff line number Diff line
@@ -16,7 +16,7 @@

package com.android.server.wm.flicker.ime

import android.platform.test.annotations.Postsubmit
import android.platform.test.annotations.Presubmit
import android.view.Surface
import android.view.WindowManagerPolicyConstants
import androidx.test.filters.RequiresDevice
@@ -59,31 +59,11 @@ class CloseImeEditorPopupDialogTest(testSpec: FlickerTestParameter) : BaseTest(t
        }
    }

    /** {@inheritDoc} */
    @Postsubmit
    @Test
    override fun taskBarWindowIsAlwaysVisible() = super.taskBarWindowIsAlwaysVisible()

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

    /** {@inheritDoc} */
    @Postsubmit
    @Test
    override fun visibleLayersShownMoreThanOneConsecutiveEntry() =
        super.visibleLayersShownMoreThanOneConsecutiveEntry()

    /** {@inheritDoc} */
    @Postsubmit
    @Test
    override fun visibleWindowsShownMoreThanOneConsecutiveEntry() =
        super.visibleWindowsShownMoreThanOneConsecutiveEntry()

    @Postsubmit @Test fun imeWindowBecameInvisible() = testSpec.imeWindowBecomesInvisible()
    fun imeWindowBecameInvisible() = testSpec.imeWindowBecomesInvisible()

    @Postsubmit
    @Presubmit
    @Test
    fun imeLayerAndImeSnapshotVisibleOnScreen() {
        testSpec.assertLayers {
@@ -96,7 +76,7 @@ class CloseImeEditorPopupDialogTest(testSpec: FlickerTestParameter) : BaseTest(t
        }
    }

    @Postsubmit
    @Presubmit
    @Test
    fun imeSnapshotAssociatedOnAppVisibleRegion() {
        testSpec.assertLayers {
+17 −3
Original line number Diff line number Diff line
@@ -27,8 +27,10 @@ import com.android.server.wm.flicker.FlickerTestParameter
import com.android.server.wm.flicker.FlickerTestParameterFactory
import com.android.server.wm.flicker.dsl.FlickerBuilder
import com.android.server.wm.flicker.helpers.ImeAppAutoFocusHelper
import com.android.server.wm.flicker.helpers.isShellTransitionsEnabled
import com.android.server.wm.flicker.helpers.setRotation
import com.android.server.wm.flicker.snapshotStartingWindowLayerCoversExactlyOnApp
import org.junit.Assume
import org.junit.FixMethodOrder
import org.junit.Test
import org.junit.runner.RunWith
@@ -78,13 +80,25 @@ class OpenImeWindowFromFixedOrientationAppTest(testSpec: FlickerTestParameter) :
    @Test
    override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()

    @Presubmit @Test fun imeWindowBecomesVisible() = testSpec.imeWindowBecomesVisible()
    @Presubmit
    @Test
    fun imeWindowBecomesVisible() = testSpec.imeWindowBecomesVisible()

    @Presubmit @Test fun imeLayerBecomesVisible() = testSpec.imeLayerBecomesVisible()
    @Presubmit
    @Test
    fun imeLayerBecomesVisible() = testSpec.imeLayerBecomesVisible()

    @Postsubmit
    @Test
    fun snapshotStartingWindowLayerCoversExactlyOnApp() {
        Assume.assumeFalse(isShellTransitionsEnabled)
        testSpec.snapshotStartingWindowLayerCoversExactlyOnApp(imeTestApp)
    }

    @Presubmit
    @Test
    fun snapshotStartingWindowLayerCoversExactlyOnApp_ShellTransit() {
        Assume.assumeTrue(isShellTransitionsEnabled)
        testSpec.snapshotStartingWindowLayerCoversExactlyOnApp(imeTestApp)
    }

+14 −11
Original line number Diff line number Diff line
@@ -16,7 +16,6 @@

package com.android.server.wm.flicker.ime

import android.platform.test.annotations.Postsubmit
import android.platform.test.annotations.Presubmit
import android.platform.test.annotations.RequiresDevice
import android.view.Surface
@@ -69,7 +68,7 @@ class OpenImeWindowToOverViewTest(testSpec: FlickerTestParameter) : BaseTest(tes
    }

    /**
     * The bars (including [ComponentMatcher.STATUS_BAR] and [ComponentMatcher.NAV_BAR]) are
     * The bars (including [ComponentNameMatcher.STATUS_BAR] and [ComponentNameMatcher.NAV_BAR]) are
     * expected to be hidden while entering overview in landscape if launcher is set to portrait
     * only. Because "showing portrait overview (launcher) in landscape display" is an intermediate
     * state depending on the touch-up to decide the intention of gesture, the display may keep in
@@ -158,24 +157,28 @@ class OpenImeWindowToOverViewTest(testSpec: FlickerTestParameter) : BaseTest(tes
    /** {@inheritDoc} */
    @Test
    @Ignore("Visibility changes depending on orientation and navigation mode")
    override fun navBarLayerIsVisibleAtStartAndEnd() {}
    override fun navBarLayerIsVisibleAtStartAndEnd() {
    }

    /** {@inheritDoc} */
    @Test
    @Ignore("Visibility changes depending on orientation and navigation mode")
    override fun navBarLayerPositionAtStartAndEnd() {}
    override fun navBarLayerPositionAtStartAndEnd() {
    }

    /** {@inheritDoc} */
    @Test
    @Ignore("Visibility changes depending on orientation and navigation mode")
    override fun statusBarLayerPositionAtStartAndEnd() {}
    override fun statusBarLayerPositionAtStartAndEnd() {
    }

    /** {@inheritDoc} */
    @Test
    @Ignore("Visibility changes depending on orientation and navigation mode")
    override fun statusBarLayerIsVisibleAtStartAndEnd() {}
    override fun statusBarLayerIsVisibleAtStartAndEnd() {
    }

    @Postsubmit
    @Presubmit
    @Test
    override fun taskBarLayerIsVisibleAtStartAndEnd() = super.taskBarLayerIsVisibleAtStartAndEnd()