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

Comparing jsr166/src/test/tck/ReentrantLockTest.java (file contents):
Revision 1.67 by jsr166, Fri Sep 29 22:31:55 2017 UTC vs.
Revision 1.69 by jsr166, Sun Jul 22 22:13:55 2018 UTC

# Line 18 | Line 18 | import java.util.concurrent.ThreadLocalR
18   import java.util.concurrent.locks.Condition;
19   import java.util.concurrent.locks.ReentrantLock;
20  
21 import junit.framework.AssertionFailedError;
21   import junit.framework.Test;
22   import junit.framework.TestSuite;
23  
# Line 88 | Line 87 | public class ReentrantLockTest extends J
87          long startTime = System.nanoTime();
88          while (!lock.hasQueuedThread(t)) {
89              if (millisElapsedSince(startTime) > LONG_DELAY_MS)
90 <                throw new AssertionFailedError("timed out");
90 >                throw new AssertionError("timed out");
91              Thread.yield();
92          }
93          assertTrue(t.isAlive());
# Line 1161 | Line 1160 | public class ReentrantLockTest extends J
1160                      await(cond, awaitMethod);
1161                      throw new AssertionError("should throw");
1162                  }
1163 <                catch (IllegalMonitorStateException expected) {}
1163 >                catch (IllegalMonitorStateException success) {}
1164                  catch (Throwable fail) { threadUnexpectedException(fail); }}};
1165          Thread rogueThread = new Thread(rogue, "rogue");
1166          threads.add(rogueThread);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines