Inline notif pipeline flag in NotifInterruptPrvdr
This change is a no-op; the flag is now enabled-by-default, so all removed code paths here are effectively dead. Bug: 200269355 Test: atest SystemUITests Change-Id: I8e56a88eb0a03a4a3d5991ea238c22746be6ad1f
This commit is contained in:
@@ -294,11 +294,6 @@ public class NotificationInterruptStateProviderImpl implements NotificationInter
|
||||
* @return true if these checks pass, false if the notification should not alert
|
||||
*/
|
||||
private boolean canAlertCommon(NotificationEntry entry) {
|
||||
if (!mFlags.isNewPipelineEnabled() && mNotificationFilter.shouldFilterOut(entry)) {
|
||||
mLogger.logNoAlertingFilteredOut(entry);
|
||||
return false;
|
||||
}
|
||||
|
||||
for (int i = 0; i < mSuppressors.size(); i++) {
|
||||
if (mSuppressors.get(i).suppressInterruptions(entry)) {
|
||||
mLogger.logNoAlertingSuppressedBy(entry, mSuppressors.get(i), /* awake */ false);
|
||||
|
||||
@@ -206,11 +206,9 @@ public class NotificationInterruptStateProviderImplTest extends SysuiTestCase {
|
||||
|
||||
@Test
|
||||
public void testDoNotRunFilterOnNewPipeline() {
|
||||
when(mFlags.isNewPipelineEnabled()).thenReturn(true);
|
||||
// WHEN this entry should be filtered out
|
||||
NotificationEntry entry = createNotification(IMPORTANCE_DEFAULT);
|
||||
mNotifInterruptionStateProvider.shouldHeadsUp(entry);
|
||||
verify(mFlags, times(1)).isNewPipelineEnabled();
|
||||
verify(mNotificationFilter, times(0)).shouldFilterOut(eq(entry));
|
||||
}
|
||||
|
||||
@@ -326,7 +324,8 @@ public class NotificationInterruptStateProviderImplTest extends SysuiTestCase {
|
||||
public void testShouldNotHeadsUp_filtered() throws RemoteException {
|
||||
ensureStateForHeadsUpWhenAwake();
|
||||
// Make canAlertCommon false by saying it's filtered out
|
||||
when(mNotificationFilter.shouldFilterOut(any())).thenReturn(true);
|
||||
when(mKeyguardNotificationVisibilityProvider.shouldHideNotification(any()))
|
||||
.thenReturn(true);
|
||||
|
||||
NotificationEntry entry = createNotification(IMPORTANCE_HIGH);
|
||||
assertThat(mNotifInterruptionStateProvider.shouldHeadsUp(entry)).isFalse();
|
||||
@@ -504,7 +503,8 @@ public class NotificationInterruptStateProviderImplTest extends SysuiTestCase {
|
||||
ensureStateForBubbleUp();
|
||||
|
||||
// Make canAlertCommon false by saying it's filtered out
|
||||
when(mNotificationFilter.shouldFilterOut(any())).thenReturn(true);
|
||||
when(mKeyguardNotificationVisibilityProvider.shouldHideNotification(any()))
|
||||
.thenReturn(true);
|
||||
|
||||
assertThat(mNotifInterruptionStateProvider.shouldBubbleUp(createBubble())).isFalse();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user