/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/batteryusage/ |
D | BatteryUsageDataLoaderTest.java | 56 @Mock private ContentResolver mMockContentResolver; field in BatteryUsageDataLoaderTest 74 doReturn(mMockContentResolver).when(mContext).getContentResolver(); in setUp() 91 verify(mMockContentResolver).insert(any(), any()); in loadUsageData_loadUsageDataWithHistory() 102 verify(mMockContentResolver).insert(any(), any()); in loadUsageData_nullBatteryEntryList_insertFakeDataIntoProvider() 113 verify(mMockContentResolver).insert(any(), any()); in loadUsageData_emptyBatteryEntryList_insertFakeDataIntoProvider() 126 verify(mMockContentResolver).bulkInsert(any(), any()); in loadAppUsageData_withData_insertFakeDataIntoProvider() 127 verify(mMockContentResolver).notifyChange(any(), any()); in loadAppUsageData_withData_insertFakeDataIntoProvider() 136 verifyNoMoreInteractions(mMockContentResolver); in loadAppUsageData_nullAppUsageEvents_notInsertDataIntoProvider() 146 verifyNoMoreInteractions(mMockContentResolver); in loadAppUsageData_nullUsageEventsList_notInsertDataIntoProvider() 156 verifyNoMoreInteractions(mMockContentResolver); in loadAppUsageData_emptyUsageEventsList_notInsertDataIntoProvider()
|
D | DatabaseUtilsTest.java | 73 @Mock private ContentResolver mMockContentResolver; field in DatabaseUtilsTest 87 doReturn(mMockContentResolver).when(mContext).getContentResolver(); in setUp() 125 verify(mMockContentResolver).bulkInsert(DatabaseUtils.APP_USAGE_EVENT_URI, valuesArray); in sendAppUsageEventData_returnsExpectedList() 126 verify(mMockContentResolver) in sendAppUsageEventData_returnsExpectedList() 135 verifyNoMoreInteractions(mMockContentResolver); in sendAppUsageEventData_emptyAppUsageEventList_notSend() 155 verify(mMockContentResolver).insert(DatabaseUtils.BATTERY_EVENT_URI, contentValues); in sendBatteryEventData_returnsExpectedList() 199 verify(mMockContentResolver).bulkInsert(DatabaseUtils.BATTERY_CONTENT_URI, valuesArray); in sendBatteryEntryData_returnsExpectedList() 200 verify(mMockContentResolver) in sendBatteryEntryData_returnsExpectedList() 219 verify(mMockContentResolver).insert(any(), any()); in sendBatteryEntryData_emptyBatteryEntryList_sendFakeDataIntoProvider() 220 verify(mMockContentResolver) in sendBatteryEntryData_emptyBatteryEntryList_sendFakeDataIntoProvider() [all …]
|
/packages/apps/Contacts/tests/src/com/android/contacts/database/ |
D | NoNullCursorAsyncQueryHandlerTest.java | 36 private MockContentResolver mMockContentResolver; field in NoNullCursorAsyncQueryHandlerTest 45 mMockContentResolver = new MockContentResolver(); in setUp() 55 mMockContentResolver.addProvider(AUTHORITY, mMockContentProvider); in setUp() 70 mMockContentResolver) { in testCursorIsNotNull() 97 mMockContentResolver) { in testCursorContainsCorrectCookies() 124 mMockContentResolver) { in testCursorContainsCorrectColumns()
|
/packages/modules/AppSearch/testing/contactsindexertests/src/com/android/server/appsearch/contactsindexer/ |
D | FakeContactsProviderTestBase.java | 46 protected MockContentResolver mMockContentResolver; field in FakeContactsProviderTestBase 52 mMockContentResolver = new MockContentResolver(context); in setUp() 57 mMockContentResolver.addProvider(FakeContactsProvider.AUTHORITY, in setUp() 76 return mMockContentResolver; in getContentResolver()
|
D | ContactsIndexerImplTest.java | 470 MockContentResolver spyContentResolver = spy(mMockContentResolver); in testContactsIndexerImpl_batchUpdateContactsNullCursor_shouldContinueOnError() 517 MockContentResolver spyContentResolver = spy(mMockContentResolver); in testContactsIndexerImpl_batchUpdateContactsNullCursor_shouldNotContinueOnError() 559 MockContentResolver spyContentResolver = spy(mMockContentResolver); in testContactsIndexerImpl_batchUpdateContactsThrows_shouldContinueOnError() 606 MockContentResolver spyContentResolver = spy(mMockContentResolver); in testContactsIndexerImpl_batchUpdateContactsThrows_shouldNotContinueOnError()
|
/packages/modules/Bluetooth/android/app/tests/unit/src/com/android/bluetooth/btservice/ |
D | DataMigrationTest.java | 73 private MockContentResolver mMockContentResolver; field in DataMigrationTest 90 mMockContentResolver = new MockContentResolver(mTargetContext); in setUp() 91 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp() 115 mMockContentResolver.addProvider(AUTHORITY, fakeContentProvider); in testEmptyMigration() 165 mMockContentResolver.addProvider(AUTHORITY, new MockContentProvider(mMockContext)); in testMissingProvider() 183 mMockContentResolver.addProvider(AUTHORITY, new MockContentProvider(mMockContext)); in testTooManyAttempt() 192 mMockContentResolver.addProvider(AUTHORITY, fakeContentProvider); in testSharedPreferencesMigration() 297 mMockContentResolver.addProvider(AUTHORITY, fakeContentProvider); in testIncompleteDbMigration() 317 mMockContentResolver.addProvider(AUTHORITY, fakeContentProvider); in testBluetoothDbMigration() 405 mMockContentResolver.addProvider(AUTHORITY, fakeContentProvider); in testOppDbMigration()
|
D | AdapterServiceTest.java | 179 private MockContentResolver mMockContentResolver; field in AdapterServiceTest 243 mMockContentResolver = new MockContentResolver(targetContext); in setUp() 244 mMockContentResolver.addProvider( in setUp() 264 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp() 600 when(mockContext.getContentResolver()).thenReturn(mMockContentResolver); in testEnableDisableOnlyGatt()
|
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/applications/assist/ |
D | AssistConfigBasePreferenceControllerTest.java | 81 private ContentResolver mMockContentResolver; field in AssistConfigBasePreferenceControllerTest 167 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in onStart_registersObserver() 172 verify(mMockContentResolver).registerContentObserver(eq(ASSIST_URI), eq(false), in onStart_registersObserver() 174 verify(mMockContentResolver).registerContentObserver(eq(ASSIST_STRUCTURE_URI), in onStart_registersObserver() 181 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in onStop_unregistersObserver() 187 verify(mMockContentResolver).unregisterContentObserver(any()); in onStop_unregistersObserver()
|
D | DefaultVoiceInputPickerEntryPreferenceControllerTest.java | 88 private ContentResolver mMockContentResolver; field in DefaultVoiceInputPickerEntryPreferenceControllerTest 234 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in onStart_registersObserver() 238 verify(mMockContentResolver).registerContentObserver(eq(ASSIST_URI), eq(false), in onStart_registersObserver() 244 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in onStop_unregistersObserver() 249 verify(mMockContentResolver).unregisterContentObserver(any()); in onStop_unregistersObserver()
|
/packages/providers/BlockedNumberProvider/tests/src/com/android/providers/blockednumber/ |
D | BlockedNumberContractTest.java | 61 private MockContentResolver mMockContentResolver = new MockContentResolver(); field in BlockedNumberContractTest 68 mMockContentResolver.addProvider(BlockedNumberContract.AUTHORITY_URI.toString(), in setUp() 70 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp()
|
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/network/ |
D | RoamingPreferenceControllerTest.java | 83 private ContentResolver mMockContentResolver; field in RoamingPreferenceControllerTest 103 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp() 129 verify(mMockContentResolver).registerContentObserver( in onStart_registerObserver() 139 verify(mMockContentResolver).registerContentObserver( in onStart_registerObserver_additionalSubId() 149 verify(mMockContentResolver).unregisterContentObserver(any()); in onStop_unregisterObserver()
|
D | MobileDataTogglePreferenceControllerTest.java | 81 private ContentResolver mMockContentResolver; field in MobileDataTogglePreferenceControllerTest 104 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp() 133 verify(mMockContentResolver).registerContentObserver(eq(uri), eq(false), any()); in onStart_singleSim_registersObserver() 142 verify(mMockContentResolver).registerContentObserver(eq(uri), eq(false), any()); in onStart_multiSim_registersObserver() 150 verify(mMockContentResolver).unregisterContentObserver(any()); in onStop_singleSim_unregistersObserver()
|
D | MobileNetworkEntryPreferenceControllerTest.java | 105 private ContentResolver mMockContentResolver; field in MobileNetworkEntryPreferenceControllerTest 128 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp() 325 verify(mMockContentResolver).registerContentObserver(eq(uri), eq(false), any()); in onStart_singleSim_registersObserver() 334 verify(mMockContentResolver).registerContentObserver(eq(uri), eq(false), any()); in onStart_multiSim_registersObserver() 342 verify(mMockContentResolver).unregisterContentObserver(any()); in onStop_singleSim_unregistersObserver()
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/bluetooth/ |
D | CarBluetoothServiceTest.java | 75 private MockContentResolver mMockContentResolver; field in CarBluetoothServiceTest 96 mMockContentResolver = new MockContentResolver(null); in setUp() 103 mMockContentResolver.addProvider(Settings.AUTHORITY, mMockContentProvider); in setUp() 106 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp()
|
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/system/ |
D | ResetNetworkConfirmFragmentTest.java | 99 private ContentResolver mMockContentResolver; field in ResetNetworkConfirmFragmentTest 128 when(mContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp() 165 verify(mMockContentResolver, times(2)).delete(argumentCaptor.capture(), any(), any()); in testResetButtonClick_cleanSmsRawTable() 240 verify(mMockContentResolver, times(2)).delete(argumentCaptor.capture(), any(), any()); in testResetButtonClick_emptyNetworkSubscriptionId_noRestoreDefaultApn() 256 verify(mMockContentResolver, times(2)).delete(argumentCaptor.capture(), any(), any()); in testResetButtonClick_validNetworkSubscriptionId_restoreDefaultApn()
|
/packages/modules/Bluetooth/android/app/tests/unit/src/com/android/bluetooth/mapclient/ |
D | MapClientContentTest.java | 97 private MockContentResolver mMockContentResolver; field in MapClientContentTest 114 mMockContentResolver = Mockito.spy(new MockContentResolver()); in setUp() 115 mMockContentResolver.addProvider("sms", mMockSmsContentProvider); in setUp() 116 mMockContentResolver.addProvider("mms", mMockMmsContentProvider); in setUp() 117 mMockContentResolver.addProvider("mms-sms", mMockThreadContentProvider); in setUp() 119 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp() 459 mMockContentResolver.addProvider("sms", missingContentProvider); in testInsertSmsFails_messageHandleNotInteractable() 481 mMockContentResolver.addProvider("mms", missingContentProvider); in testInsertMmsPartsSkippedWhenMmsInsertFails_messageHandleNotInteractable()
|
D | MapClientStateMachineTest.java | 131 private MockContentResolver mMockContentResolver; field in MapClientStateMachineTest 195 mMockContentResolver = new MockContentResolver(); in setUp() 198 mMockContentResolver.addProvider("sms", mMockContentProvider); in setUp() 199 mMockContentResolver.addProvider("mms", mMockContentProvider); in setUp() 200 mMockContentResolver.addProvider("mms-sms", mMockContentProvider); in setUp() 202 when(mMockMapClientService.getContentResolver()).thenReturn(mMockContentResolver); in setUp()
|
/packages/providers/TelephonyProvider/tests/src/com/android/providers/telephony/ |
D | TelephonyBackupAgentTest.java | 105 private MockContentResolver mMockContentResolver = new MockContentResolver(); field in TelephonyBackupAgentTest 334 mMockContentResolver.addProvider("sms", contentProvider); in setUp() 335 mMockContentResolver.addProvider("mms", contentProvider); in setUp() 336 mMockContentResolver.addProvider("mms-sms", mThreadProvider); in setUp() 342 return mMockContentResolver; in setUp() 348 mTelephonyBackupAgent.setContentResolver(mMockContentResolver); in setUp() 640 mMockContentResolver.addProvider("sms", smsProvider); in testRestoreSms_NoSms() 653 mMockContentResolver.addProvider("sms", smsProvider); in testRestoreSms_AllSms() 668 mMockContentResolver.addProvider("sms", smsProvider); in testRestoreSms_WithException() 699 mMockContentResolver.addProvider("mms", mmsProvider); in testRestoreMms_NoMms() [all …]
|
/packages/services/Telephony/tests/src/com/android/services/telephony/ |
D | TestTelephonyConnection.java | 73 ContentResolver mMockContentResolver; field in TestTelephonyConnection 158 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in TestTelephonyConnection() 162 when(mMockContentResolver.getUserId()).thenReturn(UserHandle.USER_CURRENT); in TestTelephonyConnection() 163 when(mMockContentResolver.getAttributionSource()).thenReturn(attributionSource); in TestTelephonyConnection()
|
/packages/services/Car/tests/carservice_test/src/com/android/car/garagemode/ |
D | GarageModeServiceTest.java | 51 @Mock private ContentResolver mMockContentResolver; field in GarageModeServiceTest 59 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp()
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/audio/ |
D | CarAudioSettingsUnitTest.java | 56 private ContentResolver mMockContentResolver; field in CarAudioSettingsUnitTest 73 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp()
|
D | FocusInteractionTest.java | 78 private ContentResolver mMockContentResolver; field in FocusInteractionTest 96 .thenReturn(mMockContentResolver); in setUp()
|
/packages/modules/AdServices/adservices/tests/unittest/service-core/src/com/android/adservices/service/measurement/ |
D | E2EDenoisedMockTest.java | 61 mMockContentResolver); in E2EDenoisedMockTest()
|
D | E2EMockTest.java | 138 ContentResolver mMockContentResolver; field in E2EMockTest 220 mMockContentResolver = mock(ContentResolver.class); in E2EMockTest() 222 when(mMockContentResolver.acquireContentProviderClient(TriggerContentProvider.TRIGGER_URI)) in E2EMockTest() 224 when(mMockContentResolver.acquireContentProviderClient( in E2EMockTest()
|
/packages/services/Iwlan/test/com/google/android/iwlan/ |
D | IwlanEventListenerTest.java | 70 @Mock private ContentResolver mMockContentResolver; field in IwlanEventListenerTest 112 when(mMockContext.getContentResolver()).thenReturn(mMockContentResolver); in setUp()
|