# | Line 366 | Line 366 | public class ThreadPoolExecutorTest exte | |
---|---|---|
366 | new ThreadPoolExecutor(2, 3, | |
367 | LONG_DELAY_MS, MILLISECONDS, | |
368 | new ArrayBlockingQueue<Runnable>(10)); | |
369 | < | assertEquals(3, p.getMaximumPoolSize()); |
370 | < | joinPool(p); |
369 | > | try (PoolCleaner cleaner = cleaner(p)) { |
370 | > | assertEquals(3, p.getMaximumPoolSize()); |
371 | > | p.setMaximumPoolSize(5); |
372 | > | assertEquals(5, p.getMaximumPoolSize()); |
373 | > | p.setMaximumPoolSize(4); |
374 | > | assertEquals(4, p.getMaximumPoolSize()); |
375 | > | } |
376 | } | |
377 | ||
378 | /** |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |