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

Comparing jsr166/src/test/tck/PriorityBlockingQueueTest.java (file contents):
Revision 1.81 by jsr166, Mon May 28 21:19:50 2018 UTC vs.
Revision 1.82 by jsr166, Sun Aug 11 22:29:27 2019 UTC

# Line 370 | Line 370 | public class PriorityBlockingQueueTest e
370              }});
371  
372          await(pleaseInterrupt);
373 <        assertThreadBlocks(t, Thread.State.WAITING);
373 >        if (randomBoolean()) assertThreadBlocks(t, Thread.State.WAITING);
374          t.interrupt();
375          awaitTermination(t);
376      }
# Line 428 | Line 428 | public class PriorityBlockingQueueTest e
428  
429                  Thread.currentThread().interrupt();
430                  try {
431 <                    q.poll(LONG_DELAY_MS, MILLISECONDS);
431 >                    q.poll(randomTimeout(), randomTimeUnit());
432                      shouldThrow();
433                  } catch (InterruptedException success) {}
434                  assertFalse(Thread.interrupted());
# Line 444 | Line 444 | public class PriorityBlockingQueueTest e
444              }});
445  
446          await(pleaseInterrupt);
447 <        assertThreadBlocks(t, Thread.State.TIMED_WAITING);
447 >        if (randomBoolean()) assertThreadBlocks(t, Thread.State.TIMED_WAITING);
448          t.interrupt();
449          awaitTermination(t);
450      }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines