/packages/apps/Settings/tests/robotests/src/com/android/settings/accounts/ |
D | AccountPreferenceControllerTest.java | 82 private AccountManager mAccountManager; field in AccountPreferenceControllerTest 95 shadowApp.setSystemService(Context.ACCOUNT_SERVICE, mAccountManager); in setUp() 99 when(mAccountManager.getAuthenticatorTypesAsUser(anyInt())) in setUp() 101 when(mAccountManager.getAccountsAsUser(anyInt())).thenReturn(new Account[0]); in setUp() 343 when(mAccountManager.getAccountsAsUser(anyInt())).thenReturn(accounts); in onResume_twoAccountsOfSameType_shouldAddThreePreferences() 349 when(mAccountManager.getAccountsByTypeAsUser(eq("com.acct1"), any(UserHandle.class))) in onResume_twoAccountsOfSameType_shouldAddThreePreferences() 356 when(mAccountManager.getAuthenticatorTypesAsUser(anyInt())).thenReturn(authDescs); in onResume_twoAccountsOfSameType_shouldAddThreePreferences() 396 when(mAccountManager.getAccountsAsUser(anyInt())).thenReturn(allAccounts); in onResume_twoAccountsOfSameName_shouldAddFivePreferences() 397 when(mAccountManager.getAccountsByTypeAsUser(eq("com.acct1"), any(UserHandle.class))) in onResume_twoAccountsOfSameName_shouldAddFivePreferences() 399 when(mAccountManager.getAccountsByTypeAsUser(eq("com.acct2"), any(UserHandle.class))) in onResume_twoAccountsOfSameName_shouldAddFivePreferences() [all …]
|
D | RemoveAccountPreferenceControllerTest.java | 89 private AccountManager mAccountManager; field in RemoveAccountPreferenceControllerTest 108 ShadowApplication.getInstance().setSystemService(Context.ACCOUNT_SERVICE, mAccountManager); in setUp() 115 when(mAccountManager.getAuthenticatorTypesAsUser(anyInt())) in setUp() 117 when(mAccountManager.getAccountsAsUser(anyInt())).thenReturn(new Account[0]); in setUp() 180 when(activity.getSystemService(Context.ACCOUNT_SERVICE)).thenReturn(mAccountManager); in confirmRemove_shouldRemoveAccount() 192 verify(mAccountManager).removeAccountAsUser(eq(account), nullable(Activity.class), in confirmRemove_shouldRemoveAccount() 215 when(activity.getSystemService(Context.ACCOUNT_SERVICE)).thenReturn(mAccountManager); in confirmRemove_activityGone_shouldSilentlyRemoveAccount() 226 verify(mAccountManager).removeAccountAsUser(eq(account), nullable(Activity.class), in confirmRemove_activityGone_shouldSilentlyRemoveAccount()
|
D | AccountTypePreferenceLoaderTest.java | 58 private AccountManager mAccountManager; field in AccountTypePreferenceLoaderTest 72 shadowContext.setSystemService(Context.ACCOUNT_SERVICE, mAccountManager); in setUp() 73 when(mAccountManager.getAuthenticatorTypesAsUser(anyInt())).thenReturn( in setUp() 75 when(mAccountManager.getAccountsAsUser(anyInt())).thenReturn(new Account[0]); in setUp()
|
D | AccountSyncPreferenceControllerTest.java | 56 private AccountManager mAccountManager; field in AccountSyncPreferenceControllerTest 66 ShadowApplication.getInstance().setSystemService(Context.ACCOUNT_SERVICE, mAccountManager); in setUp() 68 when(mAccountManager.getAuthenticatorTypesAsUser(anyInt())).thenReturn( in setUp() 70 when(mAccountManager.getAccountsAsUser(anyInt())).thenReturn(new Account[0]); in setUp()
|
D | AccountDashboardFragmentTest.java | 57 private AccountManager mAccountManager; field in AccountDashboardFragmentTest 108 when(AccountManager.get(mContext)).thenReturn(mAccountManager); in searchIndexProvider_hasAccounts_shouldIndex() 109 doReturn(accounts).when(mAccountManager).getAccounts(); in searchIndexProvider_hasAccounts_shouldIndex()
|
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/task/ |
D | CopyAccountToUserTaskTest.java | 66 @Mock private AccountManager mAccountManager; field in CopyAccountToUserTaskTest 78 when(mContext.getSystemService(Context.ACCOUNT_SERVICE)).thenReturn(mAccountManager); in setUp() 79 when(mAccountManager.copyAccountToUser( in setUp() 99 verify(mAccountManager).copyAccountToUser( in testRun() 123 verify(mAccountManager).copyAccountToUser( in testRun_error() 144 verifyZeroInteractions(mAccountManager); in testRun_nullAccount() 160 verifyZeroInteractions(mAccountManager); in testRun_sameUser()
|
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/accounts/ |
D | AuthUtils.java | 35 private final AccountManager mAccountManager; field in AuthUtils 38 mAccountManager = AccountManager.get(context); in AuthUtils() 45 mAccountManager.invalidateAuthToken(accountType, authToken); in invalidateAuthToken() 55 return mAccountManager.getAuthToken(account, authTokenType, options, notifyAuthFailure, in getAuthToken() 65 return mAccountManager.blockingGetAuthToken(account, authTokenType, notifyAuthFailure); in blockingGetAuthToken()
|
/packages/apps/Contacts/tests/src/com/android/contacts/tests/ |
D | AccountsTestHelper.java | 44 private final AccountManager mAccountManager; field in AccountsTestHelper 57 mAccountManager = AccountManager.get(mContext); in AccountsTestHelper() 64 assertTrue(mAccountManager.addAccountExplicitly(newAccount, null, null)); in addTestAccount() 91 mAccountManager.removeAccountExplicitly(remove); in removeTestAccount() 102 mAccountManager.getAccountsByType(TEST_ACCOUNT_TYPE)); in hasTestAccount() 121 mAccountManager.removeAccountExplicitly(account); in cleanup()
|
/packages/apps/Contacts/tests/src/com/android/contacts/model/ |
D | AccountTypeManagerTest.java | 58 @Mock private AccountManager mAccountManager; field in AccountTypeManagerTest 105 when(mAccountManager.getAccountsByType(Mockito.anyString())).thenReturn(ACCOUNTS); in testGetDefaultAccount_NoDefaultAccountPreferenceSet() 110 when(mAccountManager.getAccountsByType(Mockito.anyString())).thenReturn(ACCOUNTS); in testGetDefaultAccount_DefaultAccountPreferenceSet() 117 when(mAccountManager.getAccountsByType(Mockito.anyString())).thenReturn(ACCOUNTS); in testGetDefaultAccount_DefaultAccountPreferenceSet_NonGoogleAccountType() 124 when(mAccountManager.getAccountsByType(Mockito.anyString())).thenReturn(ACCOUNTS); in testGetDefaultAccount_DefaultAccountPreferenceSet_UnknownName() 133 mAccountManager, mPrefs, "contact_editor_default_account_key"); in getDefaultGoogleAccountName()
|
/packages/apps/Contacts/src/com/android/contacts/model/ |
D | AccountTypeManager.java | 339 private final AccountManager mAccountManager; 360 return getAccountsWithDataSets(mAccountManager.getAccounts(), typeProvider); 383 mAccountManager = AccountManager.get(mContext); 404 mAccountManager.addOnAccountsUpdatedListener(this, mMainThreadHandler, false); 475 getAccountsWithDataSets(mAccountManager.getAccounts(), mTypeProvider); 497 mAccountManager.getAuthenticatorTypes(), ContentResolver.getSyncAdapterTypes())) { 614 return getDefaultGoogleAccount(mAccountManager, sharedPreferences, defaultAccountKey); 620 mAccountManager.getAccountsByType(GoogleAccountType.ACCOUNT_TYPE); 643 final Account[] accounts = mAccountManager.getAccounts(); 694 final Account[] accounts = mAccountManager.getAccountsByType(account.type);
|
D | DeviceLocalAccountLocator.java | 88 private final AccountManager mAccountManager; field in DeviceLocalAccountLocator.NexusDeviceAccountLocator 93 mAccountManager = accountManager; in NexusDeviceAccountLocator() 99 final Account[] accounts = mAccountManager in getDeviceLocalAccounts()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/ |
D | MasterClearTest.java | 88 private AccountManager mAccountManager; field in MasterClearTest 369 when(mMockActivity.getSystemService(Context.ACCOUNT_SERVICE)).thenReturn(mAccountManager); in testGetAccountConfirmationIntent_no_relevant_accounts() 370 when(mAccountManager.getAccountsByType(TEST_ACCOUNT_TYPE)).thenReturn(accounts); in testGetAccountConfirmationIntent_no_relevant_accounts() 383 when(mMockActivity.getSystemService(Context.ACCOUNT_SERVICE)).thenReturn(mAccountManager); in testGetAccountConfirmationIntent_unresolved() 384 when(mAccountManager.getAccountsByType(TEST_ACCOUNT_TYPE)).thenReturn(accounts); in testGetAccountConfirmationIntent_unresolved() 402 when(mMockActivity.getSystemService(Context.ACCOUNT_SERVICE)).thenReturn(mAccountManager); in testTryShowAccountConfirmation_ok() 403 when(mAccountManager.getAccountsByType(TEST_ACCOUNT_TYPE)).thenReturn(accounts); in testTryShowAccountConfirmation_ok()
|
/packages/apps/Bluetooth/src/com/android/bluetooth/pbapclient/ |
D | PbapClientConnectionHandler.java | 128 private AccountManager mAccountManager; field in PbapClientConnectionHandler 148 mAccountManager = AccountManager.get(mPbapClientStateMachine.getContext()); in PbapClientConnectionHandler() 165 mAccountManager = AccountManager.get(mPbapClientStateMachine.getContext()); in PbapClientConnectionHandler() 458 if (mAccountManager.addAccountExplicitly(account, null, null)) { in addAccount() 468 if (mAccountManager.removeAccountExplicitly(account)) { in removeAccount()
|
/packages/apps/Dialer/java/com/android/contacts/common/model/ |
D | AccountTypeManager.java | 242 private AccountManager mAccountManager; field in AccountTypeManagerImpl 269 mAccountManager = AccountManager.get(mContext); in AccountTypeManagerImpl() 306 mAccountManager.addOnAccountsUpdatedListener(this, mListenerHandler, false); in AccountTypeManagerImpl() 421 final AccountManager am = mAccountManager; in loadAccountsInBackground() 518 Account[] accounts = mAccountManager.getAccounts(); in loadAccountsInBackground()
|
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/accounts/ |
D | AccountTypesHelperTest.java | 60 private AccountManager mAccountManager = AccountManager.get(application); field in AccountTypesHelperTest 180 return Shadow.extract(mAccountManager); in getShadowAccountManager()
|
D | ChooseAccountPreferenceControllerTest.java | 72 private AccountManager mAccountManager = AccountManager.get(application); field in ChooseAccountPreferenceControllerTest 171 return Shadow.extract(mAccountManager); in getShadowAccountManager()
|
D | AccountListPreferenceControllerTest.java | 64 private AccountManager mAccountManager = AccountManager.get(application); field in AccountListPreferenceControllerTest 237 return Shadow.extract(mAccountManager); in getShadowAccountManager()
|