--- jsr166/src/test/tck/PriorityBlockingQueueTest.java 2019/09/05 20:54:24 1.83 +++ jsr166/src/test/tck/PriorityBlockingQueueTest.java 2019/09/05 21:11:13 1.84 @@ -422,7 +422,6 @@ public class PriorityBlockingQueueTest e final CountDownLatch pleaseInterrupt = new CountDownLatch(1); Thread t = newStartedThread(new CheckedRunnable() { public void realRun() throws InterruptedException { - long startTime = System.nanoTime(); for (int i = 0; i < SIZE; i++) assertEquals(i, (int) q.poll(LONG_DELAY_MS, MILLISECONDS)); @@ -435,12 +434,10 @@ public class PriorityBlockingQueueTest e pleaseInterrupt.countDown(); try { - q.poll(LONG_DELAY_MS, MILLISECONDS); + q.poll(LONGER_DELAY_MS, MILLISECONDS); shouldThrow(); } catch (InterruptedException success) {} assertFalse(Thread.interrupted()); - - assertTrue(millisElapsedSince(startTime) < LONG_DELAY_MS); }}); await(pleaseInterrupt);