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

Commit 48ae6b90 authored by Nataniel Borges's avatar Nataniel Borges
Browse files

In some cases launcher is not ready at test creation, in computeTestMethods

This causes the tests to fail, instead use TAPL only when first used to prevent

Stack:java.lang.AssertionError: http://go/tapl test failure: Launcher content provider is still not enabled;

Fixes: 315061537
Test: <flicker tests in presubmit>
Change-Id: Idf8bb12693234a4a92af815f36267314388cc9f5
parent 4a4bbbfb
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -40,10 +40,9 @@ abstract class BaseTest
constructor(
    protected val flicker: LegacyFlickerTest,
    protected val instrumentation: Instrumentation = InstrumentationRegistry.getInstrumentation(),
    protected val tapl: LauncherInstrumentation = LauncherInstrumentation()
) {
    init {
        tapl.setExpectedRotationCheckEnabled(true)
    protected val tapl: LauncherInstrumentation by lazy {
        LauncherInstrumentation().also { it.expectedRotationCheckEnabled = true }
    }

    private val logTag = this::class.java.simpleName