Dynamic grouping failed the first time

-Check if Worker is null
-Add test case

Bug: 154875482
Test: make -j50 RunSettingsRoboTests
Change-Id: I84572ef77cc9a48c3133d96fd2255754bc1cf67c
This commit is contained in:
Tim Peng
2020-04-24 15:42:07 +08:00
committed by tim peng
parent c38c02eec8
commit c433a867b3
2 changed files with 9 additions and 0 deletions

View File

@@ -156,6 +156,12 @@ public class MediaOutputGroupSliceTest {
assertThat(rows).isEqualTo(3);
}
@Test
public void getSlice_nullWorker_noException() {
sMediaDeviceUpdateWorker = null;
mMediaOutputGroupSlice.getSlice();
}
@Test
public void getSlice_withOneSelectableDevice_checkTitle() {
mSelectableDevices.add(mDevice1);