Merge "Exclude implicit modes from the summary of the Modes entry in Settings" into main
This commit is contained in:
committed by
Android (Google) Code Review
commit
f9ea2a52d3
@@ -526,6 +526,18 @@ public class ZenModeSummaryHelperTest {
|
||||
assertThat(summary).isEqualTo("Juggling, Rhyming, Meandering");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void getModesSummary_excludesImplicitModes() {
|
||||
ImmutableList<ZenMode> modes = ImmutableList.of(
|
||||
TestModeBuilder.MANUAL_DND_INACTIVE,
|
||||
new TestModeBuilder().implicitForPackage("com.annoying.one").build(),
|
||||
new TestModeBuilder().setName("Chirping").build()
|
||||
);
|
||||
|
||||
String summary = mSummaryHelper.getModesSummary(modes);
|
||||
assertThat(summary).isEqualTo("Do Not Disturb, Chirping");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void getModesSummary_oneModeActive_listsActiveMode() {
|
||||
ImmutableList<ZenMode> modes = ImmutableList.of(
|
||||
|
Reference in New Issue
Block a user