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

Comparing jsr166/src/test/tck/ExchangerTest.java (file contents):
Revision 1.15 by jsr166, Tue Mar 15 19:47:06 2011 UTC vs.
Revision 1.16 by dl, Fri May 6 11:22:07 2011 UTC

# Line 75 | Line 75 | public class ExchangerTest extends JSR16
75              }});
76  
77          t.start();
78 <        Thread.sleep(SHORT_DELAY_MS);
78 >        delay(SHORT_DELAY_MS);
79          t.interrupt();
80          t.join();
81      }
# Line 91 | Line 91 | public class ExchangerTest extends JSR16
91              }});
92  
93          t.start();
94 <        Thread.sleep(SHORT_DELAY_MS);
94 >        delay(SHORT_DELAY_MS);
95          t.interrupt();
96          t.join();
97      }
# Line 123 | Line 123 | public class ExchangerTest extends JSR16
123          Thread t2 = new Thread(new CheckedRunnable() {
124              public void realRun() throws InterruptedException {
125                  assertSame(one, e.exchange(two));
126 <                Thread.sleep(SMALL_DELAY_MS);
126 >                delay(SMALL_DELAY_MS);
127                  assertSame(three, e.exchange(one));
128              }});
129          Thread t3 = new Thread(new CheckedRunnable() {
130              public void realRun() throws InterruptedException {
131 <                Thread.sleep(SMALL_DELAY_MS);
131 >                delay(SMALL_DELAY_MS);
132                  assertSame(one, e.exchange(three));
133              }});
134  
135          t1.start();
136          t2.start();
137          t3.start();
138 <        Thread.sleep(SHORT_DELAY_MS);
138 >        delay(SHORT_DELAY_MS);
139          t1.interrupt();
140          t1.join();
141          t2.join();

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines