- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 23 for newCachedThreadPool (0.25 sec)
-
android/guava-tests/test/com/google/common/util/concurrent/ExecutionListTest.java
*/ public class ExecutionListTest extends TestCase { private final ExecutionList list = new ExecutionList(); public void testRunOnPopulatedList() throws Exception { Executor exec = Executors.newCachedThreadPool(); CountDownLatch countDownLatch = new CountDownLatch(3); list.add(new MockRunnable(countDownLatch), exec); list.add(new MockRunnable(countDownLatch), exec); list.add(new MockRunnable(countDownLatch), exec);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 4.7K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/ExecutionListTest.java
*/ public class ExecutionListTest extends TestCase { private final ExecutionList list = new ExecutionList(); public void testRunOnPopulatedList() throws Exception { Executor exec = Executors.newCachedThreadPool(); CountDownLatch countDownLatch = new CountDownLatch(3); list.add(new MockRunnable(countDownLatch), exec); list.add(new MockRunnable(countDownLatch), exec); list.add(new MockRunnable(countDownLatch), exec);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 4.7K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/util/concurrent/testing/AbstractListenableFutureTest.java
public void testListenersNotifiedOnError() throws Exception { CountDownLatch successLatch = new CountDownLatch(1); CountDownLatch listenerLatch = new CountDownLatch(1); ExecutorService exec = Executors.newCachedThreadPool(); future.addListener(listenerLatch::countDown, exec); new Thread( () -> { assertThrows(CancellationException.class, future::get);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Sep 06 18:30:30 UTC 2023 - 6K bytes - Viewed (0) -
guava-testlib/src/com/google/common/util/concurrent/testing/AbstractListenableFutureTest.java
public void testListenersNotifiedOnError() throws Exception { CountDownLatch successLatch = new CountDownLatch(1); CountDownLatch listenerLatch = new CountDownLatch(1); ExecutorService exec = Executors.newCachedThreadPool(); future.addListener(listenerLatch::countDown, exec); new Thread( () -> { assertThrows(CancellationException.class, future::get);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Sep 06 18:30:30 UTC 2023 - 6K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/ListenableFutureTester.java
private final ExecutorService exec; private final ListenableFuture<?> future; private final CountDownLatch latch; public ListenableFutureTester(ListenableFuture<?> future) { this.exec = Executors.newCachedThreadPool(); this.future = checkNotNull(future); this.latch = new CountDownLatch(1); } public void setUp() { future.addListener( new Runnable() { @Override
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 3.3K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/QueuesTest.java
import static com.google.common.truth.Truth.assertThat; import static java.lang.Long.MAX_VALUE; import static java.lang.Thread.currentThread; import static java.util.concurrent.Executors.newCachedThreadPool; import static java.util.concurrent.TimeUnit.MILLISECONDS; import static java.util.concurrent.TimeUnit.NANOSECONDS; import static java.util.concurrent.TimeUnit.SECONDS; import static org.junit.Assert.assertThrows;
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 12.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/ListenableFutureTaskTest.java
} return 25; } }); @Override protected void setUp() throws Exception { super.setUp(); exec = Executors.newCachedThreadPool(); task.addListener( new Runnable() { @Override public void run() { listenerLatch.countDown(); } }, directExecutor()); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 4.7K bytes - Viewed (0) -
regression-test/src/androidTest/java/okhttp/regression/compare/AndroidHttpEngineTest.kt
.build() @After fun tearDown() { engine.shutdown() cacheDir.deleteRecursively() } @Test fun get() { val executor = Executors.newCachedThreadPool() val completableFuture = execute(engine, executor, "https://google.com/robots.txt") try { val response = completableFuture.get(10, TimeUnit.SECONDS) assertEquals(200, response.code)
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Mar 24 13:19:43 UTC 2024 - 6.2K bytes - Viewed (0) -
okhttp-tls/src/test/java/okhttp3/tls/HandshakeCertificatesTest.kt
var platform = PlatformRule() private lateinit var executorService: ExecutorService private var serverSocket: ServerSocket? = null @BeforeEach fun setUp() { executorService = Executors.newCachedThreadPool(threadFactory("HandshakeCertificatesTest")) } @AfterEach fun tearDown() { executorService.shutdown() serverSocket?.closeQuietly() } @Test fun clientAndServer() {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 11 22:09:35 UTC 2024 - 7.1K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/ListenableFutureTaskTest.java
} return 25; } }); @Override protected void setUp() throws Exception { super.setUp(); exec = Executors.newCachedThreadPool(); task.addListener( new Runnable() { @Override public void run() { listenerLatch.countDown(); } }, directExecutor()); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 4.7K bytes - Viewed (0)