Home
last modified time | relevance | path

Searched refs:mNotificationManager (Results 1 – 25 of 53) sorted by relevance

123

/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/
DCarrierNetworkNotifierTest.java85 @Mock private NotificationManager mNotificationManager; field in CarrierNetworkNotifierTest
102 .thenReturn(mNotificationManager); in setUp()
169 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_hasCarrierNetworks_notificationDisplayed()
179 verify(mNotificationManager, never()).notify(anyInt(), any()); in handleScanResults_emptyList_notificationNotDisplayed()
192 verify(mNotificationManager, never()).notify(anyInt(), any()); in handleScanResults_featureDisabled_notificationNotDisplayed()
207 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_notificationShown_emptyList_notificationCleared()
211 verify(mNotificationManager).cancel(anyInt()); in handleScanResults_notificationShown_emptyList_notificationCleared()
226 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_notificationShown_noRecommendation_notificationCleared()
231 verify(mNotificationManager).cancel(anyInt()); in handleScanResults_notificationShown_noRecommendation_notificationCleared()
246 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_notificationShown_screenOff_emptyList_notificationCleared()
[all …]
DOpenNetworkNotifierTest.java85 @Mock private NotificationManager mNotificationManager; field in OpenNetworkNotifierTest
101 .thenReturn(mNotificationManager); in setUp()
168 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_hasOpenNetworks_notificationDisplayed()
178 verify(mNotificationManager, never()).notify(anyInt(), any()); in handleScanResults_emptyList_notificationNotDisplayed()
191 verify(mNotificationManager, never()).notify(anyInt(), any()); in handleScanResults_featureDisabled_notificationNotDisplayed()
206 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_notificationShown_emptyList_notificationCleared()
210 verify(mNotificationManager).cancel(anyInt()); in handleScanResults_notificationShown_emptyList_notificationCleared()
225 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_notificationShown_noRecommendation_notificationCleared()
230 verify(mNotificationManager).cancel(anyInt()); in handleScanResults_notificationShown_noRecommendation_notificationCleared()
245 verify(mNotificationManager).notify(anyInt(), any()); in handleScanResults_notificationShown_screenOff_emptyList_notificationCleared()
[all …]
DWakeupOnboardingTest.java59 @Mock private NotificationManager mNotificationManager; field in WakeupOnboardingTest
78 .thenReturn(mNotificationManager); in setUp()
93 verify(mNotificationManager).notify(eq(WakeupNotificationFactory.ONBOARD_ID), any()); in showsNotificationIfNotOnboarded()
104 verify(mNotificationManager, never()) in doesNotShowNotificationIfAlreadyOnboarded()
117 InOrder inOrder = Mockito.inOrder(mNotificationManager); in doesNotShowNotificationIfAlreadyShowing()
118 inOrder.verify(mNotificationManager) in doesNotShowNotificationIfAlreadyShowing()
139 verify(mNotificationManager).cancel(WakeupNotificationFactory.ONBOARD_ID); in dismissNotificationAction_setsOnboarded()
163 verify(mNotificationManager).cancel(WakeupNotificationFactory.ONBOARD_ID); in turnOffWifiWakeAction_setsOnboardedAndTurnsOffWifiWake()
186 verify(mNotificationManager).cancel(WakeupNotificationFactory.ONBOARD_ID); in openWifiSettingsAction_setsOnboardedAndOpensWifiSettings()
201 verify(mNotificationManager).cancel(WakeupNotificationFactory.ONBOARD_ID); in onStopDismissesNotificationWithoutOnboarding()
[all …]
DWrongPasswordNotifierTest.java49 @Mock NotificationManager mNotificationManager; field in WrongPasswordNotifierTest
61 .thenReturn(mNotificationManager); in setUp()
78 verify(mNotificationManager).notify(eq(WrongPasswordNotifier.NOTIFICATION_ID), any()); in onWrongPasswordError()
95 reset(mNotificationManager); in onNewConnectionAttemptWithPreviousWrongPasswordError()
98 verify(mNotificationManager).cancel(any(), eq(WrongPasswordNotifier.NOTIFICATION_ID)); in onNewConnectionAttemptWithPreviousWrongPasswordError()
110 verify(mNotificationManager, never()).cancel(any(), anyInt()); in onNewConnectionAttemptWithoutPreviousWrongPasswordError()
DConnectionFailureNotifierTest.java60 @Mock private NotificationManager mNotificationManager; field in ConnectionFailureNotifierTest
77 when(mWifiInjector.getNotificationManager()).thenReturn(mNotificationManager); in setUp()
127 verify(mNotificationManager).notify( in testConnectionFailureSendRandomizationSettingsNotification()
164 verify(mNotificationManager).notify( in testWifiConfigurationMismatch()
/frameworks/base/tests/net/java/com/android/server/connectivity/
DNetworkNotificationManagerTest.java84 @Mock NotificationManager mNotificationManager; field in NetworkNotificationManagerTest
110 mManager = new NetworkNotificationManager(mCtx, mTelephonyManager, mNotificationManager); in setUp()
116 verify(mNotificationManager, times(1)) in verifyTitleByNetwork()
167 verify(mNotificationManager, times(1)).notifyAsUser(eq(tag), eq(eventId), any(), any()); in testNotificationsShownAndCleared()
168 verify(mNotificationManager, times(1)).cancelAsUser(eq(tag), eq(eventId), any()); in testNotificationsShownAndCleared()
177 verify(mNotificationManager, never()).notifyAsUser(any(), anyInt(), any(), any()); in testNoInternetNotificationsNotShownForCellular()
183 verify(mNotificationManager, times(1)).notifyAsUser(eq(tag), eq(eventId), any(), any()); in testNoInternetNotificationsNotShownForCellular()
194 verify(mNotificationManager, never()).notifyAsUser(any(), anyInt(), any(), any()); in testNotificationsNotShownIfNoInternetCapability()
204 verify(mNotificationManager, times(1)) in testDuplicatedNotificationsNoInternetThenSignIn()
209 verify(mNotificationManager, times(1)) in testDuplicatedNotificationsNoInternetThenSignIn()
[all …]
/frameworks/base/core/tests/notificationtests/src/android/app/
DNotificationStressTest.java62 private NotificationManager mNotificationManager; field in NotificationStressTest
71 mNotificationManager = (NotificationManager) mContext.getSystemService( in setUp()
74 mNotificationManager.cancelAll(); in setUp()
80 mNotificationManager.cancelAll(); in tearDown()
89 mNotificationManager.cancel(mNotifyId - 4); in testNotificationStress()
102 assertTrue(mNotificationManager.getActiveNotifications().length == MAX_NOTIFCATIONS); in testNotificationsWithShadeStress()
104 mNotificationManager.cancel(--mNotifyId); in testNotificationsWithShadeStress()
127 mNotificationManager.notify(id, notification); in sendNotification()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/
DCarrierServiceStateTrackerTest.java62 NotificationManager mNotificationManager; field in CarrierServiceStateTrackerTest
75 mNotificationManager = (NotificationManager) mContext.getSystemService( in setUp()
99 doReturn(mNotificationManager).when(mSpyCarrierSST).getNotificationManager(any()); in testCancelBothNotifications()
102 verify(mNotificationManager).cancel( in testCancelBothNotifications()
104 verify(mNotificationManager).cancel( in testCancelBothNotifications()
120 doReturn(mNotificationManager).when(mSpyCarrierSST).getNotificationManager(any()); in testSendBothNotifications()
123 verify(mNotificationManager).notify( in testSendBothNotifications()
126 verify(mNotificationManager).notify( in testSendBothNotifications()
159 verify(mNotificationManager, atLeast(1)).notify( in testSendPrefNetworkNotification()
169 verify(mNotificationManager, atLeast(1)).cancel( in testSendPrefNetworkNotification()
[all …]
/frameworks/base/services/core/java/com/android/server/wm/
DAlertWindowNotification.java55 private final NotificationManager mNotificationManager; field in AlertWindowNotification
63 mNotificationManager = in AlertWindowNotification()
90 mNotificationManager.cancel(mNotificationTag, NOTIFICATION_ID); in onCancelNotification()
92 mNotificationManager.deleteNotificationChannel(mNotificationTag); in onCancelNotification()
136 mNotificationManager.notify(mNotificationTag, NOTIFICATION_ID, builder.build()); in onPostNotification()
152 mNotificationManager.createNotificationChannelGroup(sChannelGroup); in createNotificationChannel()
158 NotificationChannel channel = mNotificationManager.getNotificationChannel(mNotificationTag); in createNotificationChannel()
168 mNotificationManager.createNotificationChannel(channel); in createNotificationChannel()
/frameworks/base/packages/MtpDocumentsProvider/src/com/android/mtp/
DMtpDocumentsService.java43 private NotificationManager mNotificationManager; field in MtpDocumentsService
54 mNotificationManager = getSystemService(NotificationManager.class); in onCreate()
93 mNotificationManager.notify(ids[i], notifications[i]); in updateForegroundState()
99 mNotificationManager.getActiveNotifications(); in updateForegroundState()
102 mNotificationManager.cancel(notification.getId()); in updateForegroundState()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/
DWrongPasswordNotifier.java46 private final NotificationManager mNotificationManager; field in WrongPasswordNotifier
52 mNotificationManager = in WrongPasswordNotifier()
97 mNotificationManager.notify(NOTIFICATION_ID, builder.build()); in showNotification()
108 mNotificationManager.cancel(null, NOTIFICATION_ID); in dismissNotification()
DWakeupOnboarding.java57 private NotificationManager mNotificationManager; field in WakeupOnboarding
190 if (mNotificationManager == null) { in getNotificationManager()
191 mNotificationManager = (NotificationManager) in getNotificationManager()
194 return mNotificationManager; in getNotificationManager()
DConnectionFailureNotifier.java48 private NotificationManager mNotificationManager; field in ConnectionFailureNotifier
62 mNotificationManager = mWifiInjector.getNotificationManager(); in ConnectionFailureNotifier()
102 mNotificationManager.notify(NO_RANDOMIZED_MAC_SUPPORT_NOTIFICATION_ID, notification); in showFailedToConnectDueToNoRandomizedMacSupportNotification()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/util/leak/
DLeakReporterTest.java51 private NotificationManager mNotificationManager; field in LeakReporterTest
59 mNotificationManager = mock(NotificationManager.class); in setup()
60 mContext.addMockSystemService(NotificationManager.class, mNotificationManager); in setup()
82 verify(mNotificationManager).notify(any(), anyInt(), any()); in testDump_postsNotification()
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/notification/
DEnableZenModeDialogTest.java59 private NotificationManager mNotificationManager; field in EnableZenModeDialogTest
83 doReturn(alarmsEnabledPolicy).when(mNotificationManager).getNotificationPolicy(); in setup()
84 mController.mNotificationManager = mNotificationManager; in setup()
168 when(mNotificationManager.getNotificationPolicy()).thenReturn( in testNoAlarmWarning()
184 when(mNotificationManager.getNotificationPolicy()).thenReturn( in testAlarmWarning()
/frameworks/base/services/tests/servicestests/src/com/android/server/locksettings/
DMockLockSettingsContext.java32 private NotificationManager mNotificationManager; field in MockLockSettingsContext
44 mNotificationManager = notificationManager; in MockLockSettingsContext()
56 return mNotificationManager; in getSystemService()
/frameworks/base/tests/StatusBar/src/com/android/statusbartest/
DStatusBarTest.java35 NotificationManager mNotificationManager; field in StatusBarTest
55 mNotificationManager = (NotificationManager) getSystemService(NOTIFICATION_SERVICE); in tests()
174 mNotificationManager.notify(id, not);
267 mNotificationManager.notify(1,
281 mNotificationManager.cancel(1);
/frameworks/base/tests/FixVibrateSetting/src/com/android/fixvibratesetting/
DFixVibrateSetting.java33 NotificationManager mNotificationManager; field in FixVibrateSetting
46 mNotificationManager = (NotificationManager)getSystemService(NOTIFICATION_SERVICE); in onCreate()
126 mNotificationManager.notify(1, n); in test()
/frameworks/base/packages/SystemUI/src/com/android/systemui/usb/
DStorageNotification.java60 private NotificationManager mNotificationManager; field in StorageNotification
93 mNotificationManager.cancelAsUser(fsUuid, SystemMessage.NOTE_STORAGE_PRIVATE,
122 mNotificationManager.cancelAsUser(null, SystemMessage.NOTE_STORAGE_MOVE,
159 mNotificationManager = mContext.getSystemService(NotificationManager.class); in start()
199 mNotificationManager.cancelAsUser(fsUuid, SystemMessage.NOTE_STORAGE_PRIVATE, in updateMissingPrivateVolumes()
224 mNotificationManager.notifyAsUser(fsUuid, SystemMessage.NOTE_STORAGE_PRIVATE, in updateMissingPrivateVolumes()
252 mNotificationManager.notifyAsUser(disk.getId(), SystemMessage.NOTE_STORAGE_DISK, in onDiskScannedInternal()
257 mNotificationManager.cancelAsUser(disk.getId(), SystemMessage.NOTE_STORAGE_DISK, in onDiskScannedInternal()
268 mNotificationManager.cancelAsUser(disk.getId(), SystemMessage.NOTE_STORAGE_DISK, in onDiskDestroyedInternal()
325 mNotificationManager.notifyAsUser(vol.getId(), SystemMessage.NOTE_STORAGE_PUBLIC, in onPublicVolumeStateChangedInternal()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/pip/tv/
DPipNotification.java54 private final NotificationManager mNotificationManager; field in PipNotification
147 mNotificationManager = (NotificationManager) context.getSystemService( in PipNotification()
195 mNotificationManager.notify(NOTIFICATION_TAG, SystemMessage.NOTE_TV_PIP, in notifyPipNotification()
201 mNotificationManager.cancel(NOTIFICATION_TAG, SystemMessage.NOTE_TV_PIP); in dismissPipNotification()
/frameworks/base/packages/PackageInstaller/src/com/android/packageinstaller/
DPackageInstalledNotificationUtils.java52 private final NotificationManager mNotificationManager; field in PackageInstalledNotificationUtils
68 mNotificationManager = context.getSystemService(NotificationManager.class); in PackageInstalledNotificationUtils()
224 mNotificationManager.createNotificationChannel(channel); in createChannel()
339 mNotificationManager.notify(mInstalledPackage, mInstalledPackage.hashCode(), in postAppInstalledNotification()
344 mNotificationManager.notify(mInstallerPackage, mInstallerPackage.hashCode(), in postAppInstalledNotification()
/frameworks/base/packages/PrintSpooler/src/com/android/printspooler/model/
DNotificationController.java68 private final NotificationManager mNotificationManager; field in NotificationController
77 mNotificationManager = (NotificationManager) in NotificationController()
81 mNotificationManager.createNotificationChannel( in NotificationController()
85 mNotificationManager.createNotificationChannel( in NotificationController()
131 mNotificationManager.cancel(removedPrintJob.flattenToString(), 0); in updateNotifications()
219 mNotificationManager.notify(printJob.getId().flattenToString(), 0, builder.build()); in createNotification()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/
DNotificationListenerTest.java63 @Mock private NotificationManager mNotificationManager; field in NotificationListenerTest
76 mContext.addMockSystemService(NotificationManager.class, mNotificationManager); in setUp()
121 when(mNotificationManager.shouldHideSilentStatusBarIcons()).thenReturn(true); in testOnConnectReadStatusBarSetting()
/frameworks/base/packages/Tethering/src/com/android/networkstack/tethering/
DTetheringNotificationUpdater.java94 private final NotificationManager mNotificationManager; field in TetheringNotificationUpdater
143 mNotificationManager = (NotificationManager) context.createContextAsUser(UserHandle.ALL, 0) in TetheringNotificationUpdater()
149 mNotificationManager.createNotificationChannel(mChannel); in TetheringNotificationUpdater()
254 mNotificationManager.cancel(null /* tag */, id); in clearNotification()
360 mNotificationManager.notify(null /* tag */, id, notification); in showNotification()
/frameworks/base/media/apex/java/android/media/
DMediaSession2Service.java78 private NotificationManager mNotificationManager; field in MediaSession2Service
103 mNotificationManager = in onCreate()
232 mNotificationManager.cancel(notification.getNotificationId()); in removeSession()
281 mNotificationManager.notify(id, notification); in onPlaybackActiveChanged()

123