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

Comparing jsr166/src/test/tck/ThreadLocalRandomTest.java (file contents):
Revision 1.2 by jsr166, Fri Jul 31 23:37:31 2009 UTC vs.
Revision 1.3 by jsr166, Tue Aug 4 10:04:47 2009 UTC

# Line 41 | Line 41 | public class ThreadLocalRandomTest exten
41      public void testSetSeed() {
42          try {
43              ThreadLocalRandom.current().setSeed(17);
44 +            shouldThrow();
45          } catch (UnsupportedOperationException success) {
46          }
47      }
# Line 119 | Line 120 | public class ThreadLocalRandomTest exten
120      public void testNextIntBoundedNeg() {
121          try {
122              int  f = ThreadLocalRandom.current().nextInt(-17);
123 +            shouldThrow();
124          } catch (IllegalArgumentException success) {
125          }
126      }
# Line 129 | Line 131 | public class ThreadLocalRandomTest exten
131      public void testNextIntBadBounds() {
132          try {
133              int  f = ThreadLocalRandom.current().nextInt(17, 2);
134 +            shouldThrow();
135          } catch (IllegalArgumentException success) {
136          }
137      }
# Line 182 | Line 185 | public class ThreadLocalRandomTest exten
185      public void testNextLongBoundedNeg() {
186          try {
187              long  f = ThreadLocalRandom.current().nextLong(-17);
188 +            shouldThrow();
189          } catch (IllegalArgumentException success) {
190          }
191      }
# Line 192 | Line 196 | public class ThreadLocalRandomTest exten
196      public void testNextLongBadBounds() {
197          try {
198              long  f = ThreadLocalRandom.current().nextLong(17, 2);
199 +            shouldThrow();
200          } catch (IllegalArgumentException success) {
201          }
202      }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines