Searched refs:BlockingAnswer (Results 1 – 4 of 4) sorted by relevance
/packages/services/Car/libs/car-test-lib/src/android/car/test/mocks/ |
D | BlockingAnswer.java | 48 public final class BlockingAnswer<T> implements Answer<T> { class 50 private static final String TAG = BlockingAnswer.class.getSimpleName(); 62 private BlockingAnswer(long timeoutMs, @NonNull Visitor<InvocationOnMock> invocator, in BlockingAnswer() method in BlockingAnswer 84 public static BlockingAnswer<Void> forVoidReturn(long timeoutMs, in forVoidReturn() 86 return new BlockingAnswer<Void>(timeoutMs, invocator, /* value= */ null); in forVoidReturn() 97 public static <T> BlockingAnswer<T> forReturn(long timeoutMs, in forReturn() 99 return new BlockingAnswer<T>(timeoutMs, invocator, value); in forReturn()
|
/packages/services/Car/tests/carservice_unit_test/src/android/car/test/mocks/ |
D | BlockingAnswerTest.java | 46 BlockingAnswer<Integer> blockingAnswer = BlockingAnswer.forReturn(TIMEOUT_MS, inv -> { in testForReturn() 68 BlockingAnswer<Void> blockingAnswer = BlockingAnswer.forVoidReturn(TIMEOUT_MS, inv -> { in testForVoidReturn()
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/user/ |
D | BaseCarUserServiceTestCase.java | 57 import android.car.test.mocks.BlockingAnswer; 773 protected BlockingAnswer<Void> mockHalSwitchLateResponse(@UserIdInt int currentUserId, in mockHalSwitchLateResponse() 785 BlockingAnswer<Void> blockingAnswer = BlockingAnswer.forVoidReturn(10_000, (invocation) -> { in mockHalSwitchLateResponse()
|
D | CarUserServiceTest.java | 76 import android.car.test.mocks.BlockingAnswer; 1560 BlockingAnswer<Void> blockingAnswer = mockHalSwitchLateResponse(mAdminUserId, in testSwitchUser_multipleCallsDifferentUser_HALRespondedLate_abandonFirstCall()
|