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.175 by jsr166, Sun Oct 11 23:07:44 2015 UTC vs.
Revision 1.176 by jsr166, Mon Oct 12 07:16:39 2015 UTC

# Line 1396 | Line 1396 | public class JSR166TestCase extends Test
1396  
1397      public void await(CountDownLatch latch) {
1398          try {
1399 <            assertTrue(latch.await(LONG_DELAY_MS, MILLISECONDS));
1399 >            if (!latch.await(LONG_DELAY_MS, MILLISECONDS))
1400 >                fail("timed out waiting for CountDownLatch for "
1401 >                     + (LONG_DELAY_MS/1000) + " sec");
1402          } catch (Throwable fail) {
1403              threadUnexpectedException(fail);
1404          }
# Line 1404 | Line 1406 | public class JSR166TestCase extends Test
1406  
1407      public void await(Semaphore semaphore) {
1408          try {
1409 <            assertTrue(semaphore.tryAcquire(LONG_DELAY_MS, MILLISECONDS));
1409 >            if (!semaphore.tryAcquire(LONG_DELAY_MS, MILLISECONDS))
1410 >                fail("timed out waiting for Semaphore for "
1411 >                     + (LONG_DELAY_MS/1000) + " sec");
1412          } catch (Throwable fail) {
1413              threadUnexpectedException(fail);
1414          }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines