|
|
|
@ -24,7 +24,6 @@ import org.junit.Assert.assertEquals
|
|
|
|
|
import org.junit.Assert.assertFalse
|
|
|
|
|
import org.junit.Assert.assertTrue
|
|
|
|
|
import org.junit.Before
|
|
|
|
|
import org.junit.Ignore
|
|
|
|
|
import org.junit.Test
|
|
|
|
|
import org.junit.runner.RunWith
|
|
|
|
|
import org.mozilla.fenix.helpers.FenixRobolectricTestRunner
|
|
|
|
@ -39,6 +38,8 @@ class TrackingProtectionExceptionsViewTest {
|
|
|
|
|
@Before
|
|
|
|
|
fun setup() {
|
|
|
|
|
mockkConstructor(TrackingProtectionExceptionsAdapter::class)
|
|
|
|
|
every { anyConstructed<TrackingProtectionExceptionsAdapter>().updateData(any()) } just Runs
|
|
|
|
|
|
|
|
|
|
container = FrameLayout(testContext)
|
|
|
|
|
interactor = mockk()
|
|
|
|
|
|
|
|
|
@ -46,7 +47,6 @@ class TrackingProtectionExceptionsViewTest {
|
|
|
|
|
container,
|
|
|
|
|
interactor
|
|
|
|
|
)
|
|
|
|
|
every { anyConstructed<TrackingProtectionExceptionsAdapter>().updateData(any()) } just Runs
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@After
|
|
|
|
@ -66,7 +66,6 @@ class TrackingProtectionExceptionsViewTest {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
|
@Ignore("With latest Robolectric/mockk: updateData() was not called")
|
|
|
|
|
fun `binds empty list to adapter`() {
|
|
|
|
|
exceptionsView.update(emptyList())
|
|
|
|
|
|
|
|
|
@ -77,7 +76,6 @@ class TrackingProtectionExceptionsViewTest {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
|
@Ignore("With latest Robolectric/mockk updateData() was not called")
|
|
|
|
|
fun `binds list with items to adapter`() {
|
|
|
|
|
val items = listOf<TrackingProtectionException>(mockk(), mockk())
|
|
|
|
|
exceptionsView.update(items)
|
|
|
|
|