ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/test/tck/ThreadPoolExecutorTest.java
(Generate patch)

Comparing jsr166/src/test/tck/ThreadPoolExecutorTest.java (file contents):
Revision 1.73 by jsr166, Sun Oct 4 01:56:51 2015 UTC vs.
Revision 1.74 by jsr166, Sun Oct 4 01:58:38 2015 UTC

# Line 306 | Line 306 | public class ThreadPoolExecutorTest exte
306              new ThreadPoolExecutor(1, 2,
307                                     LONG_DELAY_MS, MILLISECONDS,
308                                     new ArrayBlockingQueue<Runnable>(10));
309 <        RejectedExecutionHandler h = new NoOpREHandler();
310 <        p.setRejectedExecutionHandler(h);
311 <        assertSame(h, p.getRejectedExecutionHandler());
312 <        joinPool(p);
309 >        try (PoolCleaner cleaner = cleaner(p)) {
310 >            RejectedExecutionHandler handler = new NoOpREHandler();
311 >            p.setRejectedExecutionHandler(handler);
312 >            assertSame(handler, p.getRejectedExecutionHandler());
313 >        }
314      }
315  
316      /**

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines