Home
last modified time | relevance | path

Searched refs:future (Results 1 – 20 of 20) sorted by relevance

/cts/tests/tests/accounts/src/android/accounts/cts/
DAbstractAuthenticatorTests.java80 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 …]
DAccountManagerUnaffiliatedAuthenticatorTests.java254 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/libs/deviceutillegacy/src/android/webkit/cts/
DWebkitUtils.java61 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()
DWebViewOnUiThread.java487 final SettableFuture<String> future = SettableFuture.create();
488 evaluateJavascript(script, result -> future.set(result));
489 return WebkitUtils.waitForFuture(future);
567 final SettableFuture<Void> future = SettableFuture.create();
571 future.set(null);
574 WebkitUtils.waitForFuture(future);
/cts/tests/sensor/src/android/hardware/cts/helpers/sensoroperations/
DParallelSensorOperation.java98 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/tests/tests/webkit/src/android/webkit/cts/
DWebViewRenderProcessTest.java71 final SettableFuture<WebViewRenderProcess> future = SettableFuture.create();
78 future.set(result);
84 return future;
88 final SettableFuture<Boolean> future = SettableFuture.create();
97 future.set(true);
103 return future;
DWebViewTest.java1348 public Future<Integer> future() { in future() method in WebViewTest.WaitForFindResultsListener
1392 assertEquals(2, (int)WebkitUtils.waitForFuture(l.future())); in testFindAll()
1414 WebkitUtils.waitForFuture(l.future()); in testFindNext()
1471 public Future<Integer> future() { in testDocumentHasImages() method in WebViewTest.DocumentHasImageCheckHandler
1488 assertFalse(handler.future().isDone()); in testDocumentHasImages()
1491 assertEquals(1, (int)WebkitUtils.waitForFuture(handler.future())); in testDocumentHasImages()
1794 public Future<Void> future() { in testRequestImageRef() method in WebViewTest.ImageLoaded
1821 WebkitUtils.waitForFuture(imageLoaded.future()); in testRequestImageRef()
2210 final SettableFuture<Void> future = SettableFuture.create(); in testSetWebChromeClient() local
2215 future.set(null); in testSetWebChromeClient()
[all …]
/cts/tests/tests/role/src/android/app/role/cts/
DRoleManagerTest.java550 ListenerFuture future = new ListenerFuture(); in assertOnRoleHoldersChangedListenerIsNotified() local
553 sContext.getMainExecutor(), future, user)); in assertOnRoleHoldersChangedListenerIsNotified() local
557 result = future.get(TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in assertOnRoleHoldersChangedListenerIsNotified()
560 sRoleManager.removeOnRoleHoldersChangedListenerAsUser(future, user)); in assertOnRoleHoldersChangedListenerIsNotified()
570 ListenerFuture future = new ListenerFuture(); in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified() local
573 sRoleManager.addOnRoleHoldersChangedListenerAsUser(sContext.getMainExecutor(), future, in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified() local
575 sRoleManager.removeOnRoleHoldersChangedListenerAsUser(future, user); in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified()
580 future.get(UNEXPECTED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in addAndRemoveOnRoleHoldersChangedListenerAndAddRoleHolderThenIsNotNotified()
684 CallbackFuture future = new CallbackFuture(); in addRoleHolder() local
686 packageName, 0, Process.myUserHandle(), sContext.getMainExecutor(), future)); in addRoleHolder()
[all …]
/cts/tests/tests/telephony/current/src/android/telephony/cts/
DVisualVoicemailServiceTest.java162 CompletableFuture<VisualVoicemailSms> future = new CompletableFuture<>(); in testPermissionlessService_ignored() local
163 PermissionlessVisualVoicemailService.setSmsFuture(future); in testPermissionlessService_ignored()
171 future.get(EVENT_NOT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in testPermissionlessService_ignored()
523 CompletableFuture<VisualVoicemailSms> future = new CompletableFuture<>(); in getSmsFromText() local
524 MockVisualVoicemailService.setSmsFuture(future); in getSmsFromText()
534 sms = future.get(EVENT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in getSmsFromText()
544 future.get(EVENT_NOT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in getSmsFromText()
562 CompletableFuture<VisualVoicemailSms> future = new CompletableFuture<>(); in getSmsFromData() local
563 MockVisualVoicemailService.setSmsFuture(future); in getSmsFromData()
571 sms = future.get(EVENT_RECEIVED_TIMEOUT_MILLIS, TimeUnit.MILLISECONDS); in getSmsFromData()
[all …]
DMockVisualVoicemailService.java33 public static void setSmsFuture(CompletableFuture<VisualVoicemailSms> future) { in setSmsFuture() argument
34 sSmsFuture = future; in setSmsFuture()
/cts/tests/tests/graphics/src/android/graphics/cts/
DRenderTarget.java68 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/
DRenderTarget.java71 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/
DMediaPlayerFlakyNetworkTest.java227 FutureTask<MediaPlayer> future = new FutureTask<MediaPlayer>(callable); in createMediaPlayerOnMainThread() local
228 getInstrumentation().runOnMainSync(future); in createMediaPlayerOnMainThread()
229 return future.get(); in createMediaPlayerOnMainThread()
/cts/tests/tests/text/src/android/text/cts/
DEmojiTest.java311 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/tests/tests/net/src/android/net/cts/
DLocalSocketTest.java437 Future<Result> future = service.submit(callable); in runInSeparateThread() local
438 Result result = future.get(allowedTime, TimeUnit.MILLISECONDS); in runInSeparateThread()
439 if (!future.isDone()) { in runInSeparateThread()
/cts/tests/tests/permission/src/android/permission/cts/
DFileSystemPermissionTest.java897 Future<Boolean> future = null; in tryFileOpenRead() local
901 future = executor.submit(readFile); in tryFileOpenRead()
904 completed = future.get(3, TimeUnit.SECONDS); in tryFileOpenRead()
914 if (future != null) { in tryFileOpenRead()
915 future.cancel(true); in tryFileOpenRead()
/cts/tests/tests/tethering/src/android/tethering/cts/
DTetheringManagerTest.java677 private final CompletableFuture<Integer> future = new CompletableFuture<>(); field in TetheringManagerTest.EntitlementResultListener
681 future.complete(result); in onTetheringEntitlementResult()
685 return future.get(timeout, unit); in get()
/cts/tests/tests/renderscript/src/android/renderscript/cts/refocus/
Dlayered_filter_fast_d1new.rscript486 // Does not reset sharp->actual_depth, which will be used in future
540 // Does not reset sharp->actual_depth, which will be used in future
601 // Resets fields of this pixel to prepare for future layer processing (pass
608 // Does not reset sharp->actual depth, which will be used in future
648 // Resets fields of this pixel to prepare for future layer processing (pass
655 // Does not reset sharp->actual depth, which will be used in future
Dlayered_filter_fast_f32.rscript357 // Does not reset sharp->actual_depth, which will be used in future
416 // Resets fields of this pixel to prepare for future layer processing (pass
421 // Does not reset sharp->actual depth, which will be used in future
/cts/tests/tests/keystore/src/android/keystore/cts/
DKeyPairGeneratorTest.java1775 Future<Certificate[]> future = executor.submit(new Callable<Certificate[]>() { in assertSSLConnectionWithClientAuth() local
1790 Certificate[] usedClientCerts = future.get(); in assertSSLConnectionWithClientAuth()