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

Comparing jsr166/src/test/tck/JSR166TestCase.java (file contents):
Revision 1.187 by jsr166, Mon Feb 22 20:41:59 2016 UTC vs.
Revision 1.188 by jsr166, Mon Feb 22 23:16:06 2016 UTC

# Line 1466 | Line 1466 | public class JSR166TestCase extends Test
1466          return new LatchAwaiter(latch);
1467      }
1468  
1469 <    public void await(CountDownLatch latch) {
1469 >    public void await(CountDownLatch latch, long timeoutMillis) {
1470          try {
1471 <            if (!latch.await(LONG_DELAY_MS, MILLISECONDS))
1471 >            if (!latch.await(timeoutMillis, MILLISECONDS))
1472                  fail("timed out waiting for CountDownLatch for "
1473 <                     + (LONG_DELAY_MS/1000) + " sec");
1473 >                     + (timeoutMillis/1000) + " sec");
1474          } catch (Throwable fail) {
1475              threadUnexpectedException(fail);
1476          }
1477      }
1478  
1479 +    public void await(CountDownLatch latch) {
1480 +        await(latch, LONG_DELAY_MS);
1481 +    }
1482 +
1483      public void await(Semaphore semaphore) {
1484          try {
1485              if (!semaphore.tryAcquire(LONG_DELAY_MS, MILLISECONDS))

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines