--- jsr166/src/test/tck/ExecutorsTest.java 2019/12/16 22:55:54 1.51 +++ jsr166/src/test/tck/ExecutorsTest.java 2020/02/01 16:45:50 1.52 @@ -279,9 +279,12 @@ public class ExecutorsTest extends JSR16 Executors.newScheduledThreadPool(2), }; - final Runnable sleeper = new CheckedInterruptedRunnable() { + final Runnable sleeper = new CheckedRunnable() { public void realRun() throws InterruptedException { - delay(LONG_DELAY_MS); + try { + delay(LONG_DELAY_MS); + } catch(InterruptedException OK) { + } }}; List threads = new ArrayList<>(); @@ -295,6 +298,8 @@ public class ExecutorsTest extends JSR16 for (Thread thread : threads) awaitTermination(thread); for (ExecutorService executor : executors) + executor.shutdownNow(); // assumes shutdownNow interrupts threads + for (ExecutorService executor : executors) joinPool(executor); }