< prev index next >
test/jdk/java/util/concurrent/tck/ThreadPoolExecutorSubclassTest.java
Print this page
8225490: Miscellaneous changes imported from jsr166 CVS 2019-09
Reviewed-by: martin, alanb
@@ -794,11 +794,11 @@
new ArrayBlockingQueue<Runnable>(10));
final CountDownLatch threadsStarted = new CountDownLatch(poolSize);
Runnable waiter = new CheckedRunnable() { public void realRun() {
threadsStarted.countDown();
try {
- MILLISECONDS.sleep(2 * LONG_DELAY_MS);
+ MILLISECONDS.sleep(LONGER_DELAY_MS);
} catch (InterruptedException success) {}
ran.getAndIncrement();
}};
for (int i = 0; i < count; i++)
p.execute(waiter);
@@ -1667,11 +1667,11 @@
try (PoolCleaner cleaner = cleaner(e)) {
List<Callable<String>> l = new ArrayList<>();
l.add(latchAwaitingStringTask(latch));
l.add(null);
try {
- e.invokeAny(l, randomTimeout(), MILLISECONDS);
+ e.invokeAny(l, randomTimeout(), randomTimeUnit());
shouldThrow();
} catch (NullPointerException success) {}
latch.countDown();
}
}
< prev index next >