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

Commit 089cf19a authored by Nataniel Borges's avatar Nataniel Borges Committed by Android (Google) Code Review
Browse files

Merge "Reuse cached flicker objects"

parents 63979bd5 bd1da71a
Loading
Loading
Loading
Loading
+4 −1
Original line number Original line Diff line number Diff line
@@ -49,7 +49,10 @@ abstract class BaseTest @JvmOverloads constructor(
) {
) {
    init {
    init {
        testSpec.setIsTablet(
        testSpec.setIsTablet(
            WindowManagerStateHelper(instrumentation).currentState.wmState.isTablet
            WindowManagerStateHelper(
                instrumentation,
                clearCacheAfterParsing = false
            ).currentState.wmState.isTablet
        )
        )
    }
    }


+4 −1
Original line number Original line Diff line number Diff line
@@ -38,7 +38,10 @@ abstract class BaseTest @JvmOverloads constructor(
) {
) {
    init {
    init {
        testSpec.setIsTablet(
        testSpec.setIsTablet(
            WindowManagerStateHelper(instrumentation).currentState.wmState.isTablet
            WindowManagerStateHelper(
                instrumentation,
                clearCacheAfterParsing = false
            ).currentState.wmState.isTablet
        )
        )
        tapl.setExpectedRotationCheckEnabled(true)
        tapl.setExpectedRotationCheckEnabled(true)
    }
    }
+6 −1
Original line number Original line Diff line number Diff line
@@ -26,4 +26,9 @@ import com.android.server.wm.flicker.rules.ChangeDisplayOrientationRule
 * @param rotation New device rotation
 * @param rotation New device rotation
 */
 */
fun Flicker.setRotation(rotation: Int) =
fun Flicker.setRotation(rotation: Int) =
    ChangeDisplayOrientationRule.setRotation(rotation, instrumentation, wmHelper)
    ChangeDisplayOrientationRule.setRotation(
        rotation,
        instrumentation,
        clearCacheAfterParsing = false,
        wmHelper = wmHelper
)