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

Comparing jsr166/src/test/tck/SemaphoreTest.java (file contents):
Revision 1.17 by jsr166, Mon Nov 16 05:30:08 2009 UTC vs.
Revision 1.18 by jsr166, Mon Nov 16 05:58:01 2009 UTC

# Line 120 | Line 120 | public class SemaphoreTest extends JSR16
120              s.acquire();
121              s.release();
122              assertEquals(1, s.availablePermits());
123 <        } catch ( InterruptedException e) {
123 >        } catch (InterruptedException e) {
124              unexpectedException();
125          }
126      }
# Line 165 | Line 165 | public class SemaphoreTest extends JSR16
165              assertTrue(s.tryAcquire(SHORT_DELAY_MS, TimeUnit.MILLISECONDS));
166              s.release();
167              assertEquals(1, s.availablePermits());
168 <        } catch ( InterruptedException e) {
168 >        } catch (InterruptedException e) {
169              unexpectedException();
170          }
171      }
# Line 196 | Line 196 | public class SemaphoreTest extends JSR16
196              s.acquire();
197              s.release();
198              t.join();
199 <        } catch ( InterruptedException e) {
199 >        } catch (InterruptedException e) {
200              unexpectedException();
201          }
202      }
# Line 223 | Line 223 | public class SemaphoreTest extends JSR16
223              s.acquireUninterruptibly();
224              s.release();
225              t.join();
226 <        } catch ( InterruptedException e) {
226 >        } catch (InterruptedException e) {
227              unexpectedException();
228          }
229      }
# Line 255 | Line 255 | public class SemaphoreTest extends JSR16
255              s.release();
256              s.release();
257              t.join();
258 <        } catch ( InterruptedException e) {
258 >        } catch (InterruptedException e) {
259              unexpectedException();
260          }
261      }
# Line 524 | Line 524 | public class SemaphoreTest extends JSR16
524              s.release(5);
525              s.acquire(5);
526              assertEquals(1, s.availablePermits());
527 <        } catch ( InterruptedException e) {
527 >        } catch (InterruptedException e) {
528              unexpectedException();
529          }
530      }
# Line 567 | Line 567 | public class SemaphoreTest extends JSR16
567              s.release(5);
568              assertTrue(s.tryAcquire(5, SHORT_DELAY_MS, TimeUnit.MILLISECONDS));
569              assertEquals(1, s.availablePermits());
570 <        } catch ( InterruptedException e) {
570 >        } catch (InterruptedException e) {
571              unexpectedException();
572          }
573      }
# Line 589 | Line 589 | public class SemaphoreTest extends JSR16
589              assertTrue(s.tryAcquire(SHORT_DELAY_MS, TimeUnit.MILLISECONDS));
590              s.release();
591              assertEquals(1, s.availablePermits());
592 <        } catch ( InterruptedException e) {
592 >        } catch (InterruptedException e) {
593              unexpectedException();
594          }
595      }
# Line 622 | Line 622 | public class SemaphoreTest extends JSR16
622              s.release();
623              t.join();
624              assertEquals(2, s.availablePermits());
625 <        } catch ( InterruptedException e) {
625 >        } catch (InterruptedException e) {
626              unexpectedException();
627          }
628      }
# Line 650 | Line 650 | public class SemaphoreTest extends JSR16
650              s.acquire(2);
651              s.release(1);
652              t.join();
653 <        } catch ( InterruptedException e) {
653 >        } catch (InterruptedException e) {
654              unexpectedException();
655          }
656      }
# Line 679 | Line 679 | public class SemaphoreTest extends JSR16
679              s.acquire(2);
680              s.release(2);
681              t.join();
682 <        } catch ( InterruptedException e) {
682 >        } catch (InterruptedException e) {
683              unexpectedException();
684          }
685      }
# Line 715 | Line 715 | public class SemaphoreTest extends JSR16
715              s.release();
716              s.release();
717              t.join();
718 <        } catch ( InterruptedException e) {
718 >        } catch (InterruptedException e) {
719              unexpectedException();
720          }
721      }
# Line 744 | Line 744 | public class SemaphoreTest extends JSR16
744              assertTrue(s.tryAcquire(2, SHORT_DELAY_MS, TimeUnit.MILLISECONDS));
745              s.release(2);
746              t.join();
747 <        } catch ( InterruptedException e) {
747 >        } catch (InterruptedException e) {
748              unexpectedException();
749          }
750      }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines