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

Commit 059acba0 authored by Maryam Dehaini's avatar Maryam Dehaini
Browse files

Set default touchable region for PhoneStatusBarView in tests

Bug: 441898493
Flag: EXEMPT test fix
Test: ates
Change-Id: I580b3300b1a85d23041d31684be39d0fd8ebe3ca
parent e4fd8950
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -88,6 +88,7 @@ class PhoneStatusBarViewTest : SysuiTestCase() {
        view = spy(createStatusBarView(context))
        whenever(view.rootWindowInsets).thenReturn(emptyWindowInsets())
        whenever(view.viewRootImpl).thenReturn(mock(ViewRootImpl::class.java))
        view.updateTouchableRegion(DEFAULT_TOUCHABLE_REGION)

        val contextForSecondaryDisplay =
            SysuiTestableContext(
@@ -101,6 +102,8 @@ class PhoneStatusBarViewTest : SysuiTestCase() {
                )
            )
        viewForSecondaryDisplay = spy(createStatusBarView(contextForSecondaryDisplay))
        whenever(viewForSecondaryDisplay.viewRootImpl).thenReturn(mock(ViewRootImpl::class.java))
        viewForSecondaryDisplay.updateTouchableRegion(DEFAULT_TOUCHABLE_REGION)
    }

    @Test
@@ -584,4 +587,8 @@ class PhoneStatusBarViewTest : SysuiTestCase() {
            /* frameWidth = */ 0,
            /* frameHeight = */ 0,
        )

    companion object {
        val DEFAULT_TOUCHABLE_REGION = Region(0, 0, 500, 500)
    }
}