Ignore flaky tests

Bug: 178098143
Test: atest SeekBarViewModelTest
Change-Id: I412db6fe0350c631871726e820b897271545da73
This commit is contained in:
Beth Thibodeau
2021-03-11 20:02:44 -05:00
parent 9a2ae3ed4c
commit 9ac5a1d37b

View File

@@ -35,6 +35,7 @@ import com.google.common.truth.Truth.assertThat
import org.junit.After
import org.junit.Before
import org.junit.Ignore
import org.junit.Test
import org.junit.runner.RunWith
import org.mockito.ArgumentCaptor
@@ -49,7 +50,7 @@ import org.mockito.Mockito.`when` as whenever
@SmallTest
@RunWith(AndroidTestingRunner::class)
@TestableLooper.RunWithLooper
@TestableLooper.RunWithLooper(setAsMainLooper = true)
public class SeekBarViewModelTest : SysuiTestCase() {
private lateinit var viewModel: SeekBarViewModel
@@ -124,6 +125,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun updateDurationWithPlayback() {
// GIVEN that the duration is contained within the metadata
val duration = 12000L
@@ -146,6 +148,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun updateDurationWithoutPlayback() {
// GIVEN that the duration is contained within the metadata
val duration = 12000L
@@ -204,6 +207,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun updateDurationNoMetadata() {
// GIVEN that the metadata is null
whenever(mockController.getMetadata()).thenReturn(null)
@@ -235,6 +239,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun updateSeekAvailable() {
// GIVEN that seek is included in actions
val state = PlaybackState.Builder().run {
@@ -249,6 +254,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun updateSeekNotAvailable() {
// GIVEN that seek is not included in actions
val state = PlaybackState.Builder().run {
@@ -303,6 +309,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun onSeekProgressWithSeekStarting() {
val pos = 42L
with(viewModel) {
@@ -314,6 +321,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun onProgressChangedFromUser() {
// WHEN user starts dragging the seek bar
val pos = 42
@@ -614,6 +622,7 @@ public class SeekBarViewModelTest : SysuiTestCase() {
}
@Test
@Ignore
fun clearSeekBar() {
// GIVEN that the duration is contained within the metadata
val metadata = MediaMetadata.Builder().run {