/frameworks/native/services/surfaceflinger/tests/unittests/ |
D | RefreshRateStatsTest.cpp | 99 std::unordered_map<std::string, int64_t> times = mRefreshRateStats->getTotalTimes(); in TEST_F() local 100 ASSERT_EQ(1, times.size()); in TEST_F() 101 EXPECT_NE(0u, times.count("ScreenOff")); in TEST_F() 105 int screenOff = times["ScreenOff"]; in TEST_F() 109 times = mRefreshRateStats->getTotalTimes(); in TEST_F() 110 EXPECT_LT(screenOff, times["ScreenOff"]); in TEST_F() 111 EXPECT_EQ(0u, times.count("90fps")); in TEST_F() 117 times = mRefreshRateStats->getTotalTimes(); in TEST_F() 118 EXPECT_EQ(screenOff, times["ScreenOff"]); in TEST_F() 119 ASSERT_EQ(1u, times.count("90fps")); in TEST_F() [all …]
|
/frameworks/ml/nn/tools/systrace_parser/parser/ |
D | aggregate.py | 50 times = {} 54 times[app_phase] = {} 57 times[app_phase][phase] = {} 60 times[phase] = {} 87 times[app_phase][phase][layer] = zero_to_nan_if_missing(t0, phase, layer) 89 times[phase][layer] = zero_to_nan_if_missing(t, phase, layer) 90 if not times[PHASE_OVERALL][layer]: 91 times[PHASE_OVERALL][layer] = sum(nan_to_zero(times[phase][layer]) for phase in phases) 94 times[phase][LAYER_TOTAL] = max_ignoring_nans(times[phase].values()) 97 times[app_phase][phase][LAYER_TOTAL] = max_ignoring_nans(times[app_phase][phase].values()) [all …]
|
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/ |
D | AppStateTrackerTest.java | 35 import static org.mockito.Mockito.times; 752 verify(l, times(0)).updateAllJobs(); in assertNoCallbacks() 753 verify(l, times(0)).updateJobsForUid(anyInt(), anyBoolean()); in assertNoCallbacks() 754 verify(l, times(0)).updateJobsForUidPackage(anyInt(), anyString(), anyBoolean()); in assertNoCallbacks() 756 verify(l, times(0)).unblockAllUnrestrictedAlarms(); in assertNoCallbacks() 757 verify(l, times(0)).unblockAlarmsForUid(anyInt()); in assertNoCallbacks() 758 verify(l, times(0)).unblockAlarmsForUidPackage(anyInt(), anyString()); in assertNoCallbacks() 775 verify(l, times(1)).updateAllJobs(); in testPowerSaveListener() 776 verify(l, times(0)).updateJobsForUid(anyInt(), anyBoolean()); in testPowerSaveListener() 777 verify(l, times(0)).updateJobsForUidPackage(anyInt(), anyString(), anyBoolean()); in testPowerSaveListener() [all …]
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/stack/ |
D | NotificationSwipeHelperTest.java | 26 import static org.mockito.Mockito.times; 106 verify(mSwipeHelper, times(1)).setExposedMenuView(null); in testClearExposedMenuView() 122 verify(mSwipeHelper, times(1)).setTranslatingParentView(null); in testClearTranslatingParentView() 141 verify(mSwipeHelper, times(1)).setCurrentMenuRow(null); in testClearCurrentMenuRow() 154 verify(mSwipeHelper, times(1)).clearCurrentMenuRow(); in testOnDownUpdate_ExpandableNotificationRow() 155 verify(mHandler, times(1)).removeCallbacks(mFalsingCheck); in testOnDownUpdate_ExpandableNotificationRow() 156 verify(mSwipeHelper, times(1)).resetExposedMenuView(true, false); in testOnDownUpdate_ExpandableNotificationRow() 157 verify(mSwipeHelper, times(1)).initializeRow(mNotificationRow); in testOnDownUpdate_ExpandableNotificationRow() 170 verify(mSwipeHelper, times(1)).clearCurrentMenuRow(); in testOnDownUpdate_notExpandableNotificationRow() 171 verify(mHandler, times(1)).removeCallbacks(mFalsingCheck); in testOnDownUpdate_notExpandableNotificationRow() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/power/batterysaver/ |
D | FileUpdaterTest.java | 26 import static org.mockito.Mockito.times; 137 private void veriryWtf(int times) { in veriryWtf() argument 138 verify(mInjector, times(times)).injectWtf(anyOrNullString(), anyOrNull(Throwable.class)); in veriryWtf() 153 verify(mInjector, times(0)).injectWriteToFile(anyOrNullString(), anyOrNullString()); in testNoWrites() 159 verify(mInjector, times(0)).injectWriteToFile(anyOrNullString(), anyOrNullString()); in testNoWrites() 178 verify(mInjector, times(1)).injectWriteToFile("file1", "11"); in testSimpleWrite() 184 verify(mInjector, times(1)).injectWriteToFile("file1", "111"); in testSimpleWrite() 205 verify(mInjector, times(1)).injectWriteToFile("file1", "11"); in testMultiWrites() 206 verify(mInjector, times(1)).injectWriteToFile("file2", "22"); in testMultiWrites() 207 verify(mInjector, times(1)).injectWriteToFile("file3", "33"); in testMultiWrites() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/backup/transport/ |
D | DelegatingTransportTest.java | 21 import static org.mockito.Mockito.times; 78 verify(mBackupTransport, times(1)).name(); in testName() 90 verify(mBackupTransport, times(1)).configurationIntent(); in testConfigurationIntent() 102 verify(mBackupTransport, times(1)).currentDestinationString(); in testCurrentDestinationString() 114 verify(mBackupTransport, times(1)).dataManagementIntent(); in testDataManagementIntent() 126 verify(mBackupTransport, times(1)).dataManagementIntentLabel(); in testDataManagementIntentLabel() 138 verify(mBackupTransport, times(1)).transportDirName(); in testTransportDirName() 150 verify(mBackupTransport, times(1)).requestBackupTime(); in testRequestBackupTime() 162 verify(mBackupTransport, times(1)).initializeDevice(); in testInitializeDevice() 174 verify(mBackupTransport, times(1)).performBackup(mPackageInfo, mFd, mFlags); in testPerformBackup() [all …]
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/ |
D | NavigationBarRotationContextTest.java | 22 import static org.mockito.Mockito.times; 74 verify(mRotationButtonController, times(1)).setRotateSuggestionButtonState( in testOnInvalidRotationProposal() 82 verify(mRotationButtonController, times(1)).setRotateSuggestionButtonState( in testOnSameRotationProposal() 90 verify(mRotationButtonController, times(0)).setRotateSuggestionButtonState( in testOnRotationProposalShowButtonShowNav() 92 verify(mRotationButtonController, times(0)).setRotateSuggestionButtonState( in testOnRotationProposalShowButtonShowNav() 98 verify(mRotationButtonController, times(0)).setRotateSuggestionButtonState( in testOnRotationProposalShowButtonShowNav() 100 verify(mRotationButtonController, times(0)).setRotateSuggestionButtonState( in testOnRotationProposalShowButtonShowNav() 105 verify(mRotationButtonController, times(1)).setRotateSuggestionButtonState( in testOnRotationProposalShowButtonShowNav() 113 verify(mRotationButtonController, times(0)).setRotateSuggestionButtonState( in testOnRotationProposalShowButton() 115 verify(mRotationButtonController, times(0)).setRotateSuggestionButtonState( in testOnRotationProposalShowButton() [all …]
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/ |
D | SubscriptionInfoUpdaterTest.java | 31 import static org.mockito.Mockito.times; 188 verify(mSubscriptionController, times(1)).clearSubInfoRecord(eq(FAKE_SUB_ID_1)); in testSimAbsent() 194 verify(mSubscriptionController, times(1)).notifySubscriptionInfoChanged(); in testSimAbsent() 208 verify(mSubscriptionController, times(1)).clearSubInfoRecord(eq(FAKE_SUB_ID_1)); in testSimAbsentAndInactive() 214 verify(mConfigManager, times(0)).updateConfigForPhoneId(eq(FAKE_SUB_ID_1), in testSimAbsentAndInactive() 216 verify(mContext, times(0)).sendBroadcast(any(), anyString()); in testSimAbsentAndInactive() 217 verify(mSubscriptionController, times(1)).notifySubscriptionInfoChanged(); in testSimAbsentAndInactive() 228 verify(mSubscriptionContent, times(0)).put(anyString(), any()); in testSimUnknown() 233 verify(mSubscriptionController, times(0)).clearSubInfo(); in testSimUnknown() 234 verify(mSubscriptionController, times(0)).notifySubscriptionInfoChanged(); in testSimUnknown() [all …]
|
D | CarrierSignalAgentTest.java | 27 import static org.mockito.Mockito.times; 91 verify(mContext, times(count)).sendBroadcast(mCaptorIntent.capture()); in testNotifyManifestReceivers() 100 verify(mContext, times(count)).sendBroadcast(mCaptorIntent.capture()); in testNotifyManifestReceivers() 108 verify(mContext, times(count)).sendBroadcast(mCaptorIntent.capture()); in testNotifyManifestReceivers() 133 verify(mContext, times(count)).sendBroadcast(mCaptorIntent.capture()); in testNotifyRuntimeReceivers() 142 verify(mContext, times(++count)).sendBroadcast(mCaptorIntent.capture()); in testNotifyRuntimeReceivers() 152 verify(mContext, times(count)).sendBroadcast(mCaptorIntent.capture()); in testNotifyRuntimeReceivers() 181 verify(mContext, times(++count)).sendBroadcast(mCaptorIntent.capture()); in testNotify() 189 verify(mContext, times(++count)).sendBroadcast(mCaptorIntent.capture()); in testNotify() 200 verify(mContext, times(++count)).sendBroadcast(mCaptorIntent.capture()); in testNotify() [all …]
|
D | CarrierActionAgentTest.java | 21 import static org.mockito.Mockito.times; 98 verify(mDataActionHandler, times(0)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPM() 99 verify(mRadioActionHandler, times(0)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPM() 105 verify(mDataActionHandler, times(1)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPM() 108 verify(mRadioActionHandler, times(1)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPM() 119 verify(mDataActionHandler, times(2)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPM() 123 verify(mRadioActionHandler, times(2)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPM() 140 verify(mDataActionHandler, times(0)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPNChange() 141 verify(mRadioActionHandler, times(0)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPNChange() 148 verify(mDataActionHandler, times(1)).sendMessageAtTime(message.capture(), anyLong()); in testCarrierActionResetOnAPNChange() [all …]
|
D | CallManagerTest.java | 31 import static org.mockito.Mockito.times; 114 verify(mPhone, times(1)).dial(mCaptorString.capture(), dialArgsCaptor.capture()); in testBasicDial() 124 verify(mPhone, times(1)).rejectCall(); in testBasicRejectCall() 130 verify(mPhone, times(0)).sendDtmf(eq('a')); in testSendDtmf() 136 verify(mPhone, times(1)).sendDtmf(eq('a')); in testSendDtmf() 143 verify(mPhone, times(0)).startDtmf(anyChar()); in testStartDtmf() 149 verify(mPhone, times(1)).startDtmf('a'); in testStartDtmf() 156 verify(mPhone, times(0)).stopDtmf(); in testStopDtmf() 162 verify(mPhone, times(1)).stopDtmf(); in testStopDtmf() 169 verify(mPhone, times(0)).sendBurstDtmf(anyString(), anyInt(), anyInt(), (Message) any()); in testSendBurstDtmf() [all …]
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/model/ |
D | SysUiStateTest.java | 23 import static org.mockito.Mockito.times; 58 verify(mCallback, times(1)).onSystemUiStateChanged(FLAG_1); in addSingle_setFlag() 66 verify(mCallback, times(1)).onSystemUiStateChanged(FLAG_1); in addMultiple_setFlag() 67 verify(mCallback, times(1)) in addMultiple_setFlag() 78 verify(mCallback, times(1)).onSystemUiStateChanged(FLAG_1); in addMultipleRemoveOne_setFlag() 79 verify(mCallback, times(1)) in addMultipleRemoveOne_setFlag() 81 verify(mCallback, times(1)).onSystemUiStateChanged(FLAG_2); in addMultipleRemoveOne_setFlag() 89 verify(mCallback, times(1)).onSystemUiStateChanged(expected); in addMultiple_setFlags() 99 verify(mCallback, times(1)).onSystemUiStateChanged(expected1); in addMultipleRemoveOne_setFlags() 101 verify(mCallback, times(1)).onSystemUiStateChanged(expected2); in addMultipleRemoveOne_setFlags() [all …]
|
/frameworks/base/packages/Tethering/tests/unit/src/com/android/networkstack/tethering/ |
D | TetheringTest.java | 72 import static org.mockito.Mockito.times; 542 verify(mStatsManager, times(1)).registerNetworkStatsProvider(anyString(), any()); in setUp() 662 verify(mNetd, times(1)).interfaceSetCfg(any(InterfaceConfigurationParcel.class)); in verifyInterfaceServingModeStarted() 663 verify(mNetd, times(1)).tetherInterfaceAdd(ifname); in verifyInterfaceServingModeStarted() 664 verify(mNetd, times(1)).networkAddInterface(INetd.LOCAL_NET_ID, ifname); in verifyInterfaceServingModeStarted() 665 verify(mNetd, times(2)).networkAddRoute(eq(INetd.LOCAL_NET_ID), eq(ifname), in verifyInterfaceServingModeStarted() 694 verify(mNotificationUpdater, times(1)).onDownstreamChanged(DOWNSTREAM_NONE); in failingLocalOnlyHotspotLegacyApBroadcast() 707 verify(mUsbManager, times(1)).setCurrentFunctions(UsbManager.FUNCTION_NCM); in prepareNcmTethering() 718 verify(mUsbManager, times(1)).setCurrentFunctions(UsbManager.FUNCTION_RNDIS); in prepareUsbTethering() 736 verify(mNetd, times(1)).interfaceGetList(); in testUsbConfiguredBroadcastStartsTethering() [all …]
|
D | OffloadControllerTest.java | 50 import static org.mockito.Mockito.times; 191 inOrder.verify(mHardware, times(1)).getDefaultTetherOffloadDisabled(); in testNoSettingsValueDefaultDisabledDoesNotStart() 209 inOrder.verify(mHardware, times(1)).getDefaultTetherOffloadDisabled(); in testNoSettingsValueDefaultEnabledDoesStart() 210 inOrder.verify(mHardware, times(1)).initOffloadConfig(); in testNoSettingsValueDefaultEnabledDoesStart() 211 inOrder.verify(mHardware, times(1)).initOffloadControl( in testNoSettingsValueDefaultEnabledDoesStart() 225 inOrder.verify(mHardware, times(1)).getDefaultTetherOffloadDisabled(); in testSettingsAllowsStart() 226 inOrder.verify(mHardware, times(1)).initOffloadConfig(); in testSettingsAllowsStart() 227 inOrder.verify(mHardware, times(1)).initOffloadControl( in testSettingsAllowsStart() 241 inOrder.verify(mHardware, times(1)).getDefaultTetherOffloadDisabled(); in testSettingsDisablesStart() 256 inOrder.verify(mHardware, times(1)).getDefaultTetherOffloadDisabled(); in testSetUpstreamLinkPropertiesWorking() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/ |
D | ShortcutManagerTest11.java | 24 import static org.mockito.Mockito.times; 69 verify(callback, times(1)).onShortcutsAddedOrUpdated( in testShortcutChangeCallback_setDynamicShortcuts() 71 verify(callback, times(0)).onShortcutsRemoved(any(), any(), any()); in testShortcutChangeCallback_setDynamicShortcuts() 96 verify(callback, times(1)).onShortcutsAddedOrUpdated( in testShortcutChangeCallback_setDynamicShortcuts_replaceSameId() 100 verify(callback, times(1)).onShortcutsRemoved( in testShortcutChangeCallback_setDynamicShortcuts_replaceSameId() 137 verify(callback, times(1)).onShortcutsAddedOrUpdated( in testShortcutChangeCallback_setDynamicShortcuts_pinnedAndCached() 139 verify(callback, times(0)).onShortcutsRemoved(any(), any(), any()); in testShortcutChangeCallback_setDynamicShortcuts_pinnedAndCached() 161 verify(callback, times(1)).onShortcutsAddedOrUpdated( in testShortcutChangeCallback_pinShortcuts() 163 verify(callback, times(0)).onShortcutsRemoved(any(), any(), any()); in testShortcutChangeCallback_pinShortcuts() 193 verify(callback, times(1)).onShortcutsAddedOrUpdated( in testShortcutChangeCallback_pinShortcuts_unpinOthers() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/power/ |
D | ThermalManagerServiceTest.java | 217 .times(0)).notifyThrottling(any(Temperature.class)); in setUp() 219 .times(1)).onStatusChange(Temperature.THROTTLING_NONE); in setUp() 221 .times(0)).notifyThrottling(any(Temperature.class)); in setUp() 223 .times(1)).onStatusChange(Temperature.THROTTLING_NONE); in setUp() 228 .times(4)).notifyThrottling(captor.capture()); in setUp() 231 .times(0)).onStatusChange(Temperature.THROTTLING_NONE); in setUp() 234 .times(2)).notifyThrottling(captor.capture()); in setUp() 239 .times(0)).onStatusChange(Temperature.THROTTLING_NONE); in setUp() 261 .times(4)).notifyThrottling(captor.capture()); in testRegister() 264 .times(1)).onStatusChange(Temperature.THROTTLING_NONE); in testRegister() [all …]
|
/frameworks/native/libs/cputimeinstate/ |
D | testtimeinstate.cpp | 42 auto times = getUidCpuFreqTimes(0); in TEST() local 43 ASSERT_TRUE(times.has_value()); in TEST() 44 EXPECT_FALSE(times->empty()); in TEST() 108 auto times = getUidCpuFreqTimes(0); in TEST() local 109 ASSERT_TRUE(times.has_value()); in TEST() 114 ASSERT_NO_FATAL_FAILURE(TestUidTimesConsistent(*times, *concurrentTimes)); in TEST() 302 auto times = kv.second; in TEST() local 304 for (uint32_t policy = 0; policy < times.size(); ++policy) { in TEST() 305 for (uint32_t freqIdx = 0; freqIdx < times[policy].size(); ++freqIdx) { in TEST() 306 auto before = times[policy][freqIdx]; in TEST() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/accessibility/ |
D | FingerprintGestureDispatcherTest.java | 23 import static org.mockito.Mockito.times; 93 verify(mNonGestureCapturingClient, times(0)) in testOneNonCapturingService_doesNotCrashOrConsumeGestures() 95 verify(mNonGestureCapturingClient, times(0)).onFingerprintGesture(anyInt()); in testOneNonCapturingService_doesNotCrashOrConsumeGestures() 104 verify(mGestureCapturingClient, times(1)).onFingerprintGestureDetectionActiveChanged(false); in testOneCapturingService_notifiesClientOfActivityChanges() 105 verify(mGestureCapturingClient, times(0)).onFingerprintGestureDetectionActiveChanged(true); in testOneCapturingService_notifiesClientOfActivityChanges() 107 verify(mGestureCapturingClient, times(1)).onFingerprintGestureDetectionActiveChanged(false); in testOneCapturingService_notifiesClientOfActivityChanges() 108 verify(mGestureCapturingClient, times(1)).onFingerprintGestureDetectionActiveChanged(true); in testOneCapturingService_notifiesClientOfActivityChanges() 117 verify(mGestureCapturingClient, times(1)).onFingerprintGesture( in testOneCapturingService_consumesGesturesAndPassesThemAlong() 121 verify(mGestureCapturingClient, times(1)).onFingerprintGesture( in testOneCapturingService_consumesGesturesAndPassesThemAlong() 125 verify(mGestureCapturingClient, times(1)).onFingerprintGesture( in testOneCapturingService_consumesGesturesAndPassesThemAlong() [all …]
|
D | FingerprintGestureControllerTest.java | 25 import static org.mockito.Mockito.times; 78 verify(mMockFingerprintGestureCallback, times(1)) in testDetectionActiveCallback_noHandler_shouldCallback() 81 verify(mMockFingerprintGestureCallback, times(1)) in testDetectionActiveCallback_noHandler_shouldCallback() 102 verify(mMockFingerprintGestureCallback, times(0)) in testDetectionActiveCallback_withHandler_shouldPostRunnableToHandler() 105 verify(mMockFingerprintGestureCallback, times(1)) in testDetectionActiveCallback_withHandler_shouldPostRunnableToHandler() 109 verify(mMockFingerprintGestureCallback, times(0)) in testDetectionActiveCallback_withHandler_shouldPostRunnableToHandler() 112 verify(mMockFingerprintGestureCallback, times(1)) in testDetectionActiveCallback_withHandler_shouldPostRunnableToHandler() 131 verify(mMockFingerprintGestureCallback, times(1)) in testGestureCallback_noHandler_shouldCallListener() 151 verify(mMockFingerprintGestureCallback, times(0)) in testGestureCallback_withHandler_shouldPostRunnableToHandler() 154 verify(mMockFingerprintGestureCallback, times(1)) in testGestureCallback_withHandler_shouldPostRunnableToHandler()
|
/frameworks/base/core/tests/coretests/src/com/android/internal/os/ |
D | BinderDeathDispatcherTest.java | 22 import static org.mockito.Mockito.times; 230 verify(r1, times(1)).binderDied(); in testRegisterAndKill() 231 verify(r2, times(1)).binderDied(); in testRegisterAndKill() 232 verify(r3, times(1)).binderDied(); in testRegisterAndKill() 233 verify(r4, times(0)).binderDied(); in testRegisterAndKill() 234 verify(r5, times(0)).binderDied(); in testRegisterAndKill() 241 verify(r1, times(1)).binderDied(); in testRegisterAndKill() 242 verify(r2, times(0)).binderDied(); in testRegisterAndKill() 243 verify(r3, times(0)).binderDied(); in testRegisterAndKill() 244 verify(r4, times(0)).binderDied(); in testRegisterAndKill() [all …]
|
/frameworks/base/core/jni/ |
D | com_android_internal_os_KernelCpuUidBpfMapReader.cpp | 73 for (auto &[uid, times] : *data) { in KernelCpuUidFreqTimeBpfMapReader_readBpfData() 75 for (const auto &subVec : times) s += subVec.size(); in KernelCpuUidFreqTimeBpfMapReader_readBpfData() 79 copy2DVecToArray(env, ar, times); in KernelCpuUidFreqTimeBpfMapReader_readBpfData() 114 for (auto &[uid, times] : *data) { in KernelCpuUidActiveTimeBpfMapReader_readBpfData() 116 for (auto &time : times.active) time /= NSEC_PER_MSEC; in KernelCpuUidActiveTimeBpfMapReader_readBpfData() 117 jlongArray ar = getUidArray(env, sparseAr, uid, times.active.size()); in KernelCpuUidActiveTimeBpfMapReader_readBpfData() 119 env->SetLongArrayRegion(ar, 0, times.active.size(), in KernelCpuUidActiveTimeBpfMapReader_readBpfData() 120 reinterpret_cast<const jlong *>(times.active.data())); in KernelCpuUidActiveTimeBpfMapReader_readBpfData() 148 for (auto &[uid, times] : *data) { in KernelCpuUidClusterTimeBpfMapReader_readBpfData() 150 for (const auto &subVec : times.policy) s += subVec.size(); in KernelCpuUidClusterTimeBpfMapReader_readBpfData() [all …]
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/power/ |
D | PowerNotificationWarningsTest.java | 28 import static org.mockito.Mockito.times; 89 verify(mMockNotificationManager, times(1)) in testShowInvalidChargerNotification_NotifyAsUser() 91 verify(mMockNotificationManager, times(1)).cancelAsUser(anyString(), in testShowInvalidChargerNotification_NotifyAsUser() 99 verify(mMockNotificationManager, times(1)).cancelAsUser(anyString(), in testDismissInvalidChargerNotification_CancelAsUser() 106 verify(mMockNotificationManager, times(1)) in testShowLowBatteryNotification_NotifyAsUser() 108 verify(mMockNotificationManager, times(1)).cancelAsUser(anyString(), in testShowLowBatteryNotification_NotifyAsUser() 116 verify(mMockNotificationManager, times(1)).cancelAsUser(anyString(), in testDismissLowBatteryNotification_CancelAsUser() 133 verify(mMockNotificationManager, times(1)) in testShowHighTemperatureWarning_NotifyAsUser() 141 verify(mMockNotificationManager, times(1)).cancelAsUser(anyString(), in testDismissHighTemperatureWarning_CancelAsUser() 148 verify(mMockNotificationManager, times(1)) in testShowThermalShutdownWarning_NotifyAsUser() [all …]
|
/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/fuelgauge/ |
D | BatterySaverUtilsTest.java | 25 import static org.mockito.Mockito.times; 73 verify(mMockContext, times(1)).sendBroadcast(any(Intent.class)); in testSetPowerSaveMode_enable_firstCall_needWarning() 74 verify(mMockPowerManager, times(0)).setPowerSaveModeEnabled(anyBoolean()); in testSetPowerSaveMode_enable_firstCall_needWarning() 90 verify(mMockContext, times(0)).sendBroadcast(any(Intent.class)); in testSetPowerSaveMode_enable_secondCall_needWarning() 91 verify(mMockPowerManager, times(1)).setPowerSaveModeEnabled(eq(true)); in testSetPowerSaveMode_enable_secondCall_needWarning() 104 verify(mMockContext, times(0)).sendBroadcast(any(Intent.class)); in testSetPowerSaveMode_enable_thridCall_needWarning() 105 verify(mMockPowerManager, times(1)).setPowerSaveModeEnabled(eq(true)); in testSetPowerSaveMode_enable_thridCall_needWarning() 118 verify(mMockContext, times(0)).sendBroadcast(any(Intent.class)); in testSetPowerSaveMode_enable_firstCall_noWarning() 119 verify(mMockPowerManager, times(1)).setPowerSaveModeEnabled(eq(true)); in testSetPowerSaveMode_enable_firstCall_noWarning() 133 verify(mMockContext, times(0)).sendBroadcast(any(Intent.class)); in testSetPowerSaveMode_disable_firstCall_noWarning() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/compat/ |
D | PlatformCompatTest.java | 27 import static org.mockito.internal.verification.VerificationModeFactory.times; 156 verify(mListener1, times(2)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverrides() 179 verify(mListener1, times(1)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverridesTwoListeners() 191 verify(mListener1, times(1)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverridesTwoListeners() 192 verify(mListener2, times(1)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverridesTwoListeners() 204 verify(mListener1, times(2)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverridesForTest() 215 verify(mListener1, times(1)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverridesTwoListenersForTest() 227 verify(mListener1, times(1)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverridesTwoListenersForTest() 228 verify(mListener2, times(1)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnSetOverridesTwoListenersForTest() 239 verify(mListener1, times(1)).onCompatChange(PACKAGE_NAME); in testListenerCalledOnClearOverrides() [all …]
|
/frameworks/base/services/tests/servicestests/src/com/android/server/location/gnss/ |
D | GnssManagerServiceTest.java | 31 import static org.mockito.Mockito.times; 432 verify(mMockGnssBatchingProvider, times(0)).start(periodNanos, wakeOnFifoFull); 446 verify(mMockGnssBatchingProvider, times(1)).start(100L, true); 461 verify(mockBatchedLocationCallback, times(0)).onLocationBatch(mockLocationList); 477 verify(mockBatchedLocationCallback, times(1)).onLocationBatch(mockLocationList); 497 verify(mockBatchedLocationCallback1, times(0)).onLocationBatch(mockLocationList); 498 verify(mockBatchedLocationCallback2, times(1)).onLocationBatch(mockLocationList); 507 verify(mMockGnssBatchingProvider, times(0)).flush(); 515 verify(mMockGnssBatchingProvider, times(1)).flush(); 536 verify(mockBatchedLocationCallback, times(1)).onLocationBatch(mockLocationList); [all …]
|