Searched refs:listenerLatch (Results 1 – 3 of 3) sorted by relevance
41 protected final CountDownLatch listenerLatch = new CountDownLatch(1); field in ListenableFutureTaskTest67 listenerLatch.countDown(); in setUp()84 assertEquals(1, listenerLatch.getCount()); in testListenerDoesNotRunUntilTaskCompletes()93 assertEquals(1, listenerLatch.getCount()); in testListenerDoesNotRunUntilTaskCompletes()101 assertTrue(listenerLatch.await(5, TimeUnit.SECONDS)); in testListenerDoesNotRunUntilTaskCompletes()121 assertTrue(listenerLatch.await(5, TimeUnit.SECONDS)); in testListenerCalledOnException()133 listenerLatch.await(5, TimeUnit.SECONDS); in testListenerCalledOnCancelFromNotRunning()152 listenerLatch.await(5, TimeUnit.SECONDS); in testListenerCalledOnCancelFromRunning()
154 private CountDownLatch listenerLatch;162 listenerLatch.countDown();199 listenerLatch = new CountDownLatch(numListeners);202 returnValue += listenerLatch.getCount();205 returnValue += listenerLatch.getCount();215 listenerLatch = new CountDownLatch(numListeners);218 returnValue += listenerLatch.getCount();220 returnValue += listenerLatch.getCount();242 listenerLatch = new CountDownLatch(numListeners * NUM_THREADS);247 returnValue = (int) listenerLatch.getCount();[all …]
165 final CountDownLatch listenerLatch = new CountDownLatch(1); in testListenersNotifiedOnError() local172 listenerLatch.countDown(); in testListenersNotifiedOnError()195 assertTrue(listenerLatch.await(200, TimeUnit.MILLISECONDS)); in testListenersNotifiedOnError()215 final CountDownLatch listenerLatch = new CountDownLatch(listenerCount); in testAllListenersCompleteSuccessfully() local234 listenerLatch.countDown(); in testAllListenersCompleteSuccessfully()241 listenerLatch.await(500, TimeUnit.MILLISECONDS); in testAllListenersCompleteSuccessfully()