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

Commit 6ce4de53 authored by Matthew Reynolds's avatar Matthew Reynolds
Browse files

Move init to setup for failed tests, move failed tests

Bug: 397683023
Test: test manually with atest and ABTD
Flag: TEST_ONLY
Change-Id: I6150c5391cc6c3699a087bedfc52a9bcbf9ab53e
parent 29ebd786
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -65,8 +65,7 @@ class NotificationsShadeOverlayContentViewModelTest : SysuiTestCase() {

    private val kosmos = testKosmos()
    private val testScope = kosmos.testScope
    private val sceneInteractor = kosmos.sceneInteractor

    private val sceneInteractor by lazy { kosmos.sceneInteractor }
    private val underTest by lazy { kosmos.notificationsShadeOverlayContentViewModel }

    @Before
+1 −2
Original line number Diff line number Diff line
@@ -61,8 +61,7 @@ class QuickSettingsShadeOverlayContentViewModelTest : SysuiTestCase() {
            usingMediaInComposeFragment = false // This is not for the compose fragment
        }
    private val testScope = kosmos.testScope
    private val sceneInteractor = kosmos.sceneInteractor

    private val sceneInteractor by lazy { kosmos.sceneInteractor }
    private val underTest by lazy { kosmos.quickSettingsShadeOverlayContentViewModel }

    @Before
+2 −3
Original line number Diff line number Diff line
@@ -73,9 +73,8 @@ class SceneInteractorTest : SysuiTestCase() {

    private val kosmos = testKosmos()
    private val testScope = kosmos.testScope
    private val fakeSceneDataSource = kosmos.fakeSceneDataSource

    private val underTest = kosmos.sceneInteractor
    private val fakeSceneDataSource by lazy { kosmos.fakeSceneDataSource }
    private val underTest by lazy { kosmos.sceneInteractor }

    @Before
    fun setUp() {
+3 −4
Original line number Diff line number Diff line
@@ -50,11 +50,10 @@ class ShadeInteractorSceneContainerImplTest : SysuiTestCase() {

    private val kosmos = testKosmos()
    private val testScope = kosmos.testScope
    private val configurationRepository = kosmos.fakeConfigurationRepository
    private val keyguardRepository = kosmos.fakeKeyguardRepository
    private val sceneInteractor = kosmos.sceneInteractor
    private val configurationRepository by lazy { kosmos.fakeConfigurationRepository }
    private val keyguardRepository by lazy { kosmos.fakeKeyguardRepository }
    private val sceneInteractor by lazy { kosmos.sceneInteractor }
    private val shadeTestUtil by lazy { kosmos.shadeTestUtil }

    private val underTest by lazy { kosmos.shadeInteractorSceneContainerImpl }

    @Test
+6 −5
Original line number Diff line number Diff line
@@ -15,7 +15,9 @@ import com.android.systemui.deviceentry.domain.interactor.deviceEntryInteractor
import com.android.systemui.flags.EnableSceneContainer
import com.android.systemui.keyguard.data.repository.fakeDeviceEntryFingerprintAuthRepository
import com.android.systemui.keyguard.shared.model.SuccessFingerprintAuthenticationStatus
import com.android.systemui.kosmos.runCurrent
import com.android.systemui.kosmos.testScope
import com.android.systemui.kosmos.useUnconfinedTestDispatcher
import com.android.systemui.lifecycle.activateIn
import com.android.systemui.plugins.activityStarter
import com.android.systemui.scene.domain.interactor.sceneInteractor
@@ -51,12 +53,11 @@ import org.mockito.MockitoAnnotations
@RunWith(AndroidJUnit4::class)
@EnableSceneContainer
class ShadeHeaderViewModelTest : SysuiTestCase() {
    private val kosmos = testKosmos()
    private val kosmos = testKosmos().useUnconfinedTestDispatcher()
    private val testScope = kosmos.testScope
    private val mobileIconsInteractor = kosmos.fakeMobileIconsInteractor
    private val sceneInteractor = kosmos.sceneInteractor
    private val deviceEntryInteractor = kosmos.deviceEntryInteractor

    private val mobileIconsInteractor by lazy { kosmos.fakeMobileIconsInteractor }
    private val sceneInteractor by lazy { kosmos.sceneInteractor }
    private val deviceEntryInteractor by lazy { kosmos.deviceEntryInteractor }
    private val underTest by lazy { kosmos.shadeHeaderViewModel }

    @Before
Loading