/cts/tests/tests/calendarprovider/src/android/provider/cts/calendar/ |
D | CalendarTest.java | 128 static String generateCalendarOwnerEmail(String account) { in generateCalendarOwnerEmail() argument 129 return "OWNER_" + account + "@example.com"; in generateCalendarOwnerEmail() 141 String account, int seed) { in getNewCalendarValues() argument 146 values.put(Calendars.ACCOUNT_NAME, account); in getNewCalendarValues() 151 values.put(Calendars.OWNER_ACCOUNT, generateCalendarOwnerEmail(account)); in getNewCalendarValues() 204 public static int deleteCalendarByAccount(ContentResolver resolver, String account) { in deleteCalendarByAccount() argument 206 new String[] { account }); in deleteCalendarByAccount() 209 public static Cursor getCalendarsByAccount(ContentResolver resolver, String account) { in getCalendarsByAccount() argument 212 if (account != null) { in getCalendarsByAccount() 215 selectionArgs[1] = account; in getCalendarsByAccount() [all …]
|
/cts/tests/tests/accounts/common/src/android/accounts/cts/common/ |
D | TestAccountAuthenticator.java | 109 Account account, in confirmCredentials() argument 111 if (!mAccountType.equals(account.type)) { in confirmCredentials() 116 new ConfirmCredentialsTx(account, options, result)); in confirmCredentials() 120 if (account.name.startsWith(Fixtures.PREFIX_NAME_SUCCESS)) { in confirmCredentials() 123 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in confirmCredentials() 124 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in confirmCredentials() 125 } else if (account.name.startsWith(Fixtures.PREFIX_NAME_INTERVENE)) { in confirmCredentials() 129 eventualActivityResultData.putExtra(AccountManager.KEY_ACCOUNT_NAME, account.name); in confirmCredentials() 130 eventualActivityResultData.putExtra(AccountManager.KEY_ACCOUNT_TYPE, account.type); in confirmCredentials() 155 Account account, in getAuthToken() argument [all …]
|
D | TestDefaultAuthenticator.java | 80 Account account, in confirmCredentials() argument 89 Account account, in getAuthToken() argument 105 Account account, in updateCredentials() argument 108 if (!mAccountType.equals(account.type)) { in updateCredentials() 112 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in updateCredentials() 113 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in updateCredentials() 115 new UpdateCredentialsTx(account, authTokenType, options, result)); in updateCredentials() 122 Account account, in hasFeatures() argument
|
/cts/tests/tests/syncmanager/apps/app1/src/android/content/syncmanager/cts/app/ |
D | SyncManagerCtsAuthenticator.java | 66 final Account account = new Account(name, getAccountType()); in ensureTestAccount() local 69 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in ensureTestAccount() 70 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in ensureTestAccount() 72 if (!Arrays.asList(getAccountManager().getAccountsByType(account.type)).contains(account)) { in ensureTestAccount() 73 Log.i(TAG, "Adding account: " + account); in ensureTestAccount() 74 getAccountManager().addAccountExplicitly(account, "password", new Bundle()); in ensureTestAccount() 84 for (Account account : am.getAccountsByType(getAccountType())) { in removeAllAccounts() 85 Log.i(TAG, "Removing " + account + "..."); in removeAllAccounts() 86 am.removeAccountExplicitly(account); in removeAllAccounts() 116 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument [all …]
|
D | SyncManagerCtsSyncAdapter.java | 57 SyncResult onPerformSync(Account account, Bundle extras, String authority, in onPerformSync() argument 64 public void onPerformSync(Account account, Bundle extras, String authority, in onPerformSync() argument 68 Log.i(TAG, "onPerformSync: account=" + account + " authority=" + authority in onPerformSync() 74 .setAccountName(account.name) in onPerformSync() 75 .setAccountType(account.type) in onPerformSync() 81 getContext().getContentResolver().setIsSyncable(account, authority, 1); in onPerformSync() 84 sSyncInterceptor.onPerformSync(account, extras, authority, syncResult); in onPerformSync() 101 Log.i(TAG, "onPerformSyncFinishing: account=" + account + " authority=" + authority in onPerformSync()
|
/cts/hostsidetests/statsdatom/apps/statsdapp/src/com/android/server/cts/device/statsdatom/ |
D | StatsdAuthenticator.java | 59 final Account account = getTestAccount(); in ensureTestAccount() local 62 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in ensureTestAccount() 63 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in ensureTestAccount() 67 if (!Arrays.asList(am.getAccountsByType(account.type)).contains(account) ){ in ensureTestAccount() 68 am.addAccountExplicitly(account, "password", new Bundle()); in ensureTestAccount() 78 for (Account account : am.getAccountsByType(ACCOUNT_TYPE)) { in removeAllAccounts() 79 Log.i(TAG, "Removing " + account + "..."); in removeAllAccounts() 80 am.removeAccountExplicitly(account); in removeAllAccounts() 107 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument 113 public Bundle confirmCredentials(AccountAuthenticatorResponse response, Account account, in confirmCredentials() argument [all …]
|
/cts/hostsidetests/incident/apps/batterystatsapp/src/com/android/server/cts/device/batterystats/ |
D | BatteryStatsAuthenticator.java | 60 final Account account = getTestAccount(); in ensureTestAccount() local 63 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in ensureTestAccount() 64 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in ensureTestAccount() 68 if (!Arrays.asList(am.getAccountsByType(account.type)).contains(account) ){ in ensureTestAccount() 69 am.addAccountExplicitly(account, "password", new Bundle()); in ensureTestAccount() 79 for (Account account : am.getAccountsByType(BatteryStatsAuthenticator.ACCOUNT_TYPE)) { in removeAllAccounts() 80 Log.i(TAG, "Removing " + account + "..."); in removeAllAccounts() 81 am.removeAccountExplicitly(account); in removeAllAccounts() 108 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument 114 public Bundle confirmCredentials(AccountAuthenticatorResponse response, Account account, in confirmCredentials() argument [all …]
|
D | BatteryStatsSyncAdapter.java | 54 public void onPerformSync(Account account, Bundle extras, String authority, in onPerformSync() argument 101 public static void requestSync(Account account) throws Exception { in requestSync() argument 109 ContentResolver.requestSync(account, BatteryStatsProvider.AUTHORITY, extras); in requestSync() 117 public static void cancelPendingSyncs(Account account) throws Exception { in cancelPendingSyncs() argument 120 ContentResolver.cancelSync(account, BatteryStatsProvider.AUTHORITY); in cancelPendingSyncs() 123 if (!ContentResolver.isSyncPending(account, BatteryStatsProvider.AUTHORITY) in cancelPendingSyncs() 124 && !ContentResolver.isSyncActive(account, BatteryStatsProvider.AUTHORITY)) { in cancelPendingSyncs()
|
/cts/hostsidetests/devicepolicy/app/AccountCheck/Auth/src/com/android/cts/devicepolicy/accountcheck/ |
D | AccountCheckTest.java | 51 for (Account account : mAccountManager.getAccountsByType(ACCOUNT_TYPE)) { in testRemoveAllAccounts() 52 Log.i(TAG, "Removing account: " + account); in testRemoveAllAccounts() 53 mAccountManager.removeAccountExplicitly(account); in testRemoveAllAccounts() 149 for (Account account : accounts) { in testCheckPreconfiguredAccountFeatures() 150 Log.v(TAG, "Checking " + account); in testCheckPreconfiguredAccountFeatures() 151 if (hasAccountFeatures(am, account, feature_disallow)) { in testCheckPreconfiguredAccountFeatures() 152 error.append(account + " has " + feature_disallow[0] + "\n"); in testCheckPreconfiguredAccountFeatures() 154 if (!hasAccountFeatures(am, account, feature_allow)) { in testCheckPreconfiguredAccountFeatures() 155 error.append(account + " doesn't have " + feature_allow[0] + "\n"); in testCheckPreconfiguredAccountFeatures() 163 private boolean hasAccountFeatures(AccountManager am, Account account, String[] features) { in hasAccountFeatures() argument [all …]
|
/cts/hostsidetests/devicepolicy/app/AccountCheck/Tester/ |
D | README.txt | 4 Note: AccountCheckHostSideTest should pass even with a pre-existing ALLOWED account. Meaning, even 5 after you followed the below steps to add an ALLOWED account, AccountCheckHostSideTest should 15 - Add an account with DEVICE_OR_PROFILE_OWNER_ALLOWED. 17 --esa features android.account.DEVICE_OR_PROFILE_OWNER_ALLOWED \ 20 - Add an account with DEVICE_OR_PROFILE_OWNER_DISALLOWED. 22 --esa features android.account.DEVICE_OR_PROFILE_OWNER_DISALLOWED \ 26 $ dumpsys-account 29 …Account {name=8894956487610:android.account.DEVICE_OR_PROFILE_OWNER_ALLOWED, type=com.android.cts.…
|
/cts/tests/tests/accounts/common/src/android/accounts/cts/common/tx/ |
D | GetAccountRemovalAllowedTx.java | 24 public final Account account; field in GetAccountRemovalAllowedTx 28 account = in.readParcelable(null); in GetAccountRemovalAllowedTx() 33 Account account, in GetAccountRemovalAllowedTx() argument 35 this.account = account; in GetAccountRemovalAllowedTx() 46 out.writeParcelable(account, flags); in writeToParcel()
|
D | StartUpdateCredentialsSessionTx.java | 24 public final Account account; field in StartUpdateCredentialsSessionTx 29 account = in.readParcelable(null); in StartUpdateCredentialsSessionTx() 35 Account account, in StartUpdateCredentialsSessionTx() argument 38 this.account = account; in StartUpdateCredentialsSessionTx() 50 out.writeParcelable(account, flags); in writeToParcel()
|
D | ConfirmCredentialsTx.java | 24 public final Account account; field in ConfirmCredentialsTx 29 account = in.readParcelable(null); in ConfirmCredentialsTx() 35 Account account, in ConfirmCredentialsTx() argument 38 this.account = account; in ConfirmCredentialsTx() 50 out.writeParcelable(account, flags); in writeToParcel()
|
D | GetAuthTokenTx.java | 24 public final Account account; field in GetAuthTokenTx 30 account = in.readParcelable(null); in GetAuthTokenTx() 37 Account account, in GetAuthTokenTx() argument 41 this.account = account; in GetAuthTokenTx() 54 out.writeParcelable(account, flags); in writeToParcel()
|
D | HasFeaturesTx.java | 27 public final Account account; field in HasFeaturesTx 32 account = in.readParcelable(null); in HasFeaturesTx() 38 Account account, in HasFeaturesTx() argument 41 this.account = account; in HasFeaturesTx() 57 out.writeParcelable(account, flags); in writeToParcel()
|
D | UpdateCredentialsTx.java | 24 public final Account account; field in UpdateCredentialsTx 30 account = in.readParcelable(null); in UpdateCredentialsTx() 37 Account account, in UpdateCredentialsTx() argument 41 this.account = account; in UpdateCredentialsTx() 54 out.writeParcelable(account, flags); in writeToParcel()
|
/cts/hostsidetests/accounts/test-apps/AccountManagerCrossUserApp/src/com/android/cts/accountmanager/ |
D | MockAuthenticator.java | 60 final Account account = getTestAccount(); in addTestAccount() local 63 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in addTestAccount() 64 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in addTestAccount() 68 if (!Arrays.asList(am.getAccountsByType(account.type)).contains(account) ){ in addTestAccount() 69 am.addAccountExplicitly(account, "password", new Bundle()); in addTestAccount() 110 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument 116 public Bundle confirmCredentials(AccountAuthenticatorResponse response, Account account, in confirmCredentials() argument 125 public Bundle getAuthToken(AccountAuthenticatorResponse response, Account account, in getAuthToken() argument 136 public Bundle hasFeatures(AccountAuthenticatorResponse response, Account account, in hasFeatures() argument
|
/cts/hostsidetests/multiuser/app/src/com/android/cts/multiuser/ |
D | MockAuthenticator.java | 61 final Account account = getTestAccount(); in addTestAccount() local 64 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in addTestAccount() 65 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in addTestAccount() 69 if (!Arrays.asList(am.getAccountsByType(account.type)).contains(account)) { in addTestAccount() 70 am.addAccountExplicitly(account, "password", new Bundle()); in addTestAccount() 111 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument 117 public Bundle confirmCredentials(AccountAuthenticatorResponse response, Account account, in confirmCredentials() argument 126 public Bundle getAuthToken(AccountAuthenticatorResponse response, Account account, in getAuthToken() argument 137 public Bundle hasFeatures(AccountAuthenticatorResponse response, Account account, in hasFeatures() argument
|
/cts/hostsidetests/devicepolicy/app/ManagedProfile/src/com/android/cts/managedprofile/ |
D | AccountAuthenticator.java | 83 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument 89 public Bundle confirmCredentials(AccountAuthenticatorResponse response, Account account, in confirmCredentials() argument 98 public Bundle getAuthToken(AccountAuthenticatorResponse response, Account account, in getAuthToken() argument 109 public Bundle hasFeatures(AccountAuthenticatorResponse response, Account account, in hasFeatures() argument 118 …ic Bundle getAccountCredentialsForCloning(AccountAuthenticatorResponse response, Account account) { in getAccountCredentialsForCloning() argument 119 if (TEST_ACCOUNT.equals(account)) { in getAccountCredentialsForCloning() 122 Log.e(TAG, "failed in getAccountCredentialsForCloning. account: " + account); in getAccountCredentialsForCloning() 128 public Bundle addAccountFromCredentials(AccountAuthenticatorResponse response, Account account, in addAccountFromCredentials() argument 130 if (accountCredentials != null && TEST_ACCOUNT.equals(account) in addAccountFromCredentials() 136 + " account: " + account); in addAccountFromCredentials()
|
/cts/hostsidetests/devicepolicy/app/AccountCheck/Tester/src/com/android/cts/devicepolicy/accountcheck/tester/ |
D | TestAuthenticator.java | 75 final Account account = new Account(name, accountType); in createAccount() local 77 account, "password", new Bundle()); in createAccount() 78 return account; in createAccount() 102 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument 108 public Bundle confirmCredentials(AccountAuthenticatorResponse response, Account account, in confirmCredentials() argument 114 public Bundle getAuthToken(AccountAuthenticatorResponse response, Account account, in getAuthToken() argument 125 public Bundle hasFeatures(AccountAuthenticatorResponse response, Account account, in hasFeatures() argument 128 final int p = account.name.indexOf(':'); in hasFeatures() 132 Arrays.asList(TextUtils.split(account.name.substring(p + 1), ",")); in hasFeatures() 140 Log.i(TAG, "Checking feature for account '" + account + "' for features=" in hasFeatures()
|
/cts/tests/tests/accounts/src/android/accounts/cts/ |
D | AccountTest.java | 10 private Account account; field in AccountTest 14 account = new Account("abc@xyz.org", "com.my.auth"); in setUp() 34 assertEquals(0, account.describeContents()); in testDescribeContents() 40 account.writeToParcel(parcel, 0); in testWriteToParcel() 46 assertEquals(account, newAccount); in testWriteToParcel()
|
D | MockAccountAuthenticator.java | 177 public Bundle updateCredentials(AccountAuthenticatorResponse response, Account account, in updateCredentials() argument 180 this.mAccount = account; in updateCredentials() 202 public Bundle confirmCredentials(AccountAuthenticatorResponse response, Account account, in confirmCredentials() argument 205 this.mAccount = account; in confirmCredentials() 225 Account account, in getAuthToken() argument 231 this.mAccount = account; in getAuthToken() 236 result.putString(AccountManager.KEY_ACCOUNT_NAME, account.name); in getAuthToken() 237 result.putString(AccountManager.KEY_ACCOUNT_TYPE, account.type); in getAuthToken() 267 public Bundle hasFeatures(AccountAuthenticatorResponse response, Account account, in hasFeatures() argument 271 this.mAccount = account; in hasFeatures() [all …]
|
/cts/tests/tests/contactsprovider/src/android/provider/cts/contacts/ |
D | RawContactUtil.java | 42 public static long createRawContactWithName(ContentResolver resolver, Account account, in createRawContactWithName() argument 44 Long rawContactId = insertRawContact(resolver, account); in createRawContactWithName() 50 Account account) { in createRawContactWithAutoGeneratedName() argument 51 Long rawContactId = insertRawContact(resolver, account); in createRawContactWithAutoGeneratedName() 56 public static long insertRawContact(ContentResolver resolver, Account account) { in insertRawContact() argument 58 if (account != null) { in insertRawContact() 59 values.put(ContactsContract.RawContacts.ACCOUNT_NAME, account.name); in insertRawContact() 60 values.put(ContactsContract.RawContacts.ACCOUNT_TYPE, account.type); in insertRawContact()
|
/cts/tests/tests/content/SyncAccountAccessStubs/src/com/android/cts/stub/ |
D | StubAuthenticator.java | 79 Account account, Bundle bundle) throws NetworkErrorException { in confirmCredentials() argument 85 Account account, String type, Bundle bundle) throws NetworkErrorException { in getAuthToken() argument 99 Account account, String tokenType, Bundle bundle) in updateCredentials() argument 106 Account account, String[] options) throws NetworkErrorException { in hasFeatures() argument 112 Account account) throws NetworkErrorException { in getAccountRemovalAllowed() argument 120 for (Account account : accountManager.getAccounts()) { in removeAccounts() 121 accountManager.removeAccountExplicitly(account); in removeAccounts()
|
/cts/tests/tests/content/src/android/content/cts/ |
D | ContentResolverSyncTestCase.java | 82 private void addAccountExplicitly(Account account, String password, Bundle userdata) { in addAccountExplicitly() argument 83 assertTrue(sAccountManager.addAccountExplicitly(account, password, userdata)); in addAccountExplicitly() 86 private boolean removeAccount(AccountManager am, Account account, in removeAccount() argument 90 AccountManagerFuture<Boolean> futureBoolean = am.removeAccount(account, in removeAccount() 105 private void addAccountAndVerifyInitSync(Account account, String password, in addAccountAndVerifyInitSync() argument 110 addAccountExplicitly(account, password, null /* userData */); in addAccountAndVerifyInitSync() 124 assertEquals(account, getMockSyncAdapter().getAccounts().get(accountIndex)); in addAccountAndVerifyInitSync() 128 private void cancelSync(Account account, String authority, int latchTimeoutMillis) { in cancelSync() argument 134 ContentResolver.cancelSync(account, authority); in cancelSync() 158 private void requestSync(Account account, String authority, int latchTimeoutMillis) { in requestSync() argument [all …]
|