/cts/tests/tests/accounts/src/android/accounts/cts/ |
D | AbstractAuthenticatorTests.java | 80 AccountManagerFuture<Bundle> future = mAccountManager.startAddAccountSession( in testStartAddAccountSessionDefaultImpl() local 89 Bundle result = future.getResult(); in testStartAddAccountSessionDefaultImpl() 116 AccountManagerFuture<Bundle> future = mAccountManager.startUpdateCredentialsSession( in testStartUpdateCredentialsSessionDefaultImpl() local 124 Bundle result = future.getResult(); in testStartUpdateCredentialsSessionDefaultImpl() 125 assertTrue(future.isDone()); in testStartUpdateCredentialsSessionDefaultImpl() 156 AccountManagerFuture<Bundle> future = mAccountManager.startAddAccountSession( in testFinishSessionAndStartAddAccountSessionDefaultImpl() local 165 Bundle result = future.getResult(); in testFinishSessionAndStartAddAccountSessionDefaultImpl() 166 assertTrue(future.isDone()); in testFinishSessionAndStartAddAccountSessionDefaultImpl() 174 future = mAccountManager.finishSession( in testFinishSessionAndStartAddAccountSessionDefaultImpl() 180 result = future.getResult(); in testFinishSessionAndStartAddAccountSessionDefaultImpl() [all …]
|
D | AccountManagerUnaffiliatedAuthenticatorTests.java | 254 AccountManagerFuture<Account[]> future = mAccountManager.getAccountsByTypeAndFeatures( in testGetAccountsByTypeAndFeatures() local 259 Account[] accounts = future.getResult(); in testGetAccountsByTypeAndFeatures() 285 AccountManagerFuture<Bundle> future = mAccountManager.startAddAccountSession( in testStartAddAccountSession() local 294 Bundle result = future.getResult(); in testStartAddAccountSession() 295 assertTrue(future.isDone()); in testStartAddAccountSession() 323 AccountManagerFuture<Bundle> future = mAccountManager.startUpdateCredentialsSession( in testStartUpdateCredentialsSession() local 331 Bundle result = future.getResult(); in testStartUpdateCredentialsSession() 332 assertTrue(future.isDone()); in testStartUpdateCredentialsSession() 364 AccountManagerFuture<Bundle> future = mAccountManager.startAddAccountSession( in testDefaultFinishSessiontWithStartAddAccountSessionImpl() local 373 Bundle result = future.getResult(); in testDefaultFinishSessiontWithStartAddAccountSessionImpl() [all …]
|
/cts/tests/tests/permission/src/android/permission/cts/ |
D | PlatformPermissionGroupMappingTest.kt | 35 val future = CompletableFuture<String>() in platformPermissionHasPermissionGroup() constant 38 ) { future.complete(it) } in platformPermissionHasPermissionGroup() 39 val permissionGroupName = future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS) in platformPermissionHasPermissionGroup() 45 val future = CompletableFuture<List<String>>() in platformPermissionGroupHasPermission() constant 48 ) { future.complete(it) } in platformPermissionGroupHasPermission() 49 val permissionNames = future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS) in platformPermissionGroupHasPermission()
|
/cts/libs/deviceutillegacy/src/android/webkit/cts/ |
D | WebkitUtils.java | 61 final SettableFuture<T> future = SettableFuture.create(); in onMainThread() local 66 future.set(callable.call()); in onMainThread() 68 future.setException(t); in onMainThread() 72 return future; in onMainThread() 141 public static <T> T waitForFuture(Future<T> future) { in waitForFuture() argument 143 return future.get(TEST_TIMEOUT_MS, TimeUnit.MILLISECONDS); in waitForFuture()
|
D | WebViewOnUiThread.java | 487 final SettableFuture<String> future = SettableFuture.create(); 488 evaluateJavascript(script, result -> future.set(result)); 489 return WebkitUtils.waitForFuture(future); 565 final SettableFuture<Void> future = SettableFuture.create(); 569 future.set(null); 572 WebkitUtils.waitForFuture(future);
|
/cts/tests/tests/permission3/src/android/permission3/cts/ |
D | StartForFutureActivity.kt | 25 private val future = CompletableFuture<Instrumentation.ActivityResult>() constant 29 return future in startActivityForFuture() 35 future.complete(Instrumentation.ActivityResult(resultCode, data)) in onActivityResult()
|
D | PermissionPolicyTest25.kt | 50 val future = startActivityForFuture( in testNoProtectionFlagsAddedToNonSignatureProtectionPermissions() constant 57 val result = future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS) in testNoProtectionFlagsAddedToNonSignatureProtectionPermissions()
|
D | BaseUsePermissionTest.kt | 206 val future = startActivityForFuture( in <lambda>() constant 215 expectedResultCode, future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS).resultCode in <lambda>() 243 val future = startActivityForFuture( in <lambda>() constant 254 return future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS) in <lambda>() 646 val future = startActivityForFuture( in <lambda>() constant 653 val result = future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS) in <lambda>()
|
/cts/tests/tests/webkit/src/android/webkit/cts/ |
D | WebViewRenderProcessTest.java | 74 final SettableFuture<WebViewRenderProcess> future = SettableFuture.create(); 81 future.set(result); 87 return future; 91 final SettableFuture<Boolean> future = SettableFuture.create(); 100 future.set(true); 106 return future;
|
/cts/tests/sensor/src/android/hardware/cts/helpers/sensoroperations/ |
D | ParallelSensorOperation.java | 98 Future<SensorOperation> future = executor.submit(new Callable<SensorOperation>() { in execute() local 105 futures.add(future); in execute() 118 Future<SensorOperation> future = futures.get(i); in execute() local 120 SensorOperation operation = getFutureResult(future, executionTimeNs); in execute() 131 future.cancel(true /* mayInterruptIfRunning */); in execute() 164 private SensorOperation getFutureResult(Future<SensorOperation> future, Long timeoutNs) in getFutureResult() argument 167 return future.get(); in getFutureResult() 171 return future.get(waitTimeNs, TimeUnit.NANOSECONDS); in getFutureResult()
|
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/ |
D | FutureResultActivity.kt | 53 val future = CompletableFuture<Int>() in startActivityForResult() constant 54 requests[requestCode] = future in startActivityForResult() 56 return future in startActivityForResult()
|
/cts/tests/tests/role/src/android/app/role/cts/ |
D | RoleControllerManagerTest.kt | 98 val future = CompletableFuture<Boolean>() in assertAppIsVisibleForRole() constant 100 roleName, packageName, context.mainExecutor, Consumer { future.complete(it) } in assertAppIsVisibleForRole() 102 val isVisible = future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS) in assertAppIsVisibleForRole() 124 val future = CompletableFuture<Boolean>() in isRoleVisible() constant 126 roleName, context.mainExecutor, Consumer { future.complete(it) } in isRoleVisible() 128 future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS) in isRoleVisible()
|
D | RoleManagerTest.java | 800 ListenerFuture future = new ListenerFuture(); in assertOnRoleHoldersChangedListenerIsNotified() local 803 sContext.getMainExecutor(), future, user)); in assertOnRoleHoldersChangedListenerIsNotified() local 807 result = future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in assertOnRoleHoldersChangedListenerIsNotified() 810 sRoleManager.removeOnRoleHoldersChangedListenerAsUser(future, user)); in assertOnRoleHoldersChangedListenerIsNotified() 820 ListenerFuture future = new ListenerFuture(); in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified() local 823 sRoleManager.addOnRoleHoldersChangedListenerAsUser(sContext.getMainExecutor(), future, in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified() local 825 sRoleManager.removeOnRoleHoldersChangedListenerAsUser(future, user); in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified() 830 future.get(UNEXPECTED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified() 1010 CallbackFuture future = new CallbackFuture(); in addRoleHolder() local 1012 packageName, 0, Process.myUserHandle(), sContext.getMainExecutor(), future)); in addRoleHolder() [all …]
|
/cts/tests/tests/voiceinteraction/src/android/voiceinteraction/cts/ |
D | VoiceInteractionRoleTest.java | 145 final CallbackFuture future = new CallbackFuture("addAssistRoleHolder"); in addAssistRoleHolder() local 149 sContext.getMainExecutor(), future); in addAssistRoleHolder() 151 assertThat(future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS)).isTrue(); in addAssistRoleHolder() 157 final CallbackFuture future = new CallbackFuture("removeAssistRoleHolder"); in removeAssistRoleHolder() local 160 0, Process.myUserHandle(), sContext.getMainExecutor(), future)); in removeAssistRoleHolder() 161 assertThat(future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS)).isTrue(); in removeAssistRoleHolder()
|
/cts/tests/tests/telephony/current/src/android/telephony/cts/ |
D | MockVisualVoicemailService.java | 33 public static void setSmsFuture(CompletableFuture<VisualVoicemailSms> future) { in setSmsFuture() argument 34 sSmsFuture = future; in setSmsFuture()
|
D | VisualVoicemailServiceTest.java | 166 CompletableFuture<VisualVoicemailSms> future = new CompletableFuture<>(); in testPermissionlessService_ignored() local 167 PermissionlessVisualVoicemailService.setSmsFuture(future); in testPermissionlessService_ignored() 175 future.get(EVENT_NOT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in testPermissionlessService_ignored() 527 CompletableFuture<VisualVoicemailSms> future = new CompletableFuture<>(); in getSmsFromText() local 528 MockVisualVoicemailService.setSmsFuture(future); in getSmsFromText() 538 sms = future.get(EVENT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in getSmsFromText() 548 future.get(EVENT_NOT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in getSmsFromText() 566 CompletableFuture<VisualVoicemailSms> future = new CompletableFuture<>(); in getSmsFromData() local 567 MockVisualVoicemailService.setSmsFuture(future); in getSmsFromData() 575 sms = future.get(EVENT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in getSmsFromData() [all …]
|
/cts/hostsidetests/multiuser/app/src/com/android/cts/multiuser/ |
D | AccountCreator.java | 51 final AccountManagerFuture<Bundle> future = accountManager.addAccount( in addMockAccountForCurrentUser() local 55 final Bundle result = future.getResult(); in addMockAccountForCurrentUser()
|
/cts/common/device-side/bedstead/remoteframeworkclasses/src/types/main/java/com/android/bedstead/remoteframeworkclasses/ |
D | AccountManagerFutureWrapper.java | 56 AccountManagerFuture<V> future, FutureResultWriter<V> futureResultWriter) { in writeFutureResult() argument 58 futureResultWriter.onSuccess(future.getResult()); in writeFutureResult()
|
/cts/tests/tests/graphics/src/android/graphics/cts/ |
D | RenderTarget.java | 68 GenericFuture<RenderTarget> future = new GenericFuture<>(); in create() local 69 Message.obtain(sHandler, CREATE_SINK, future).sendToTarget(); in create() 71 return future.get(); in create()
|
/cts/tests/tests/security/src/android/security/cts/ |
D | RenderTarget.java | 71 GenericFuture<RenderTarget> future = new GenericFuture<>(); in create() local 72 Message.obtain(sHandler, CREATE_SINK, future).sendToTarget(); in create() 74 return future.get(); in create()
|
/cts/tests/tests/media/src/android/media/cts/ |
D | MediaPlayerFlakyNetworkTest.java | 229 FutureTask<MediaPlayer> future = new FutureTask<MediaPlayer>(callable); in createMediaPlayerOnMainThread() local 230 getInstrumentation().runOnMainSync(future); in createMediaPlayerOnMainThread() 231 return future.get(); in createMediaPlayerOnMainThread()
|
/cts/tests/tests/telecom/src/android/telecom/cts/ |
D | CarModeInCallServiceTest.java | 697 CompletableFuture<ICtsCarModeInCallServiceControl> future = in getControlBinder() local 702 future.complete(android.telecom.cts.carmodetestapp in getControlBinder() 708 future.complete(null); in getControlBinder() 714 return future.get(ASYNC_TIMEOUT, TimeUnit.MILLISECONDS); in getControlBinder()
|
D | SelfManagedConnectionTest.java | 327 CompletableFuture<Boolean> future = new CompletableFuture<>(); in setDefaultDialer() local 329 future.complete(successful); in setDefaultDialer() 335 return future.get(TIMEOUT, TimeUnit.MILLISECONDS); in setDefaultDialer()
|
/cts/tests/tests/text/src/android/text/cts/ |
D | EmojiTest.java | 311 final SettableFuture<Void> future = SettableFuture.create(); in capture() local 315 future.set(null); in capture() 319 future.get(TEST_TIMEOUT_MS, TimeUnit.MILLISECONDS); in capture()
|
/cts/hostsidetests/accounts/test-apps/AccountManagerCrossUserApp/src/com/android/cts/accountmanager/ |
D | AccountManagerCrossUserTest.java | 98 AccountManagerFuture<Bundle> future = accountManagerAsUser.addAccount( in testAccountManager_addMockAccount() local 102 Bundle result = future.getResult(); in testAccountManager_addMockAccount()
|