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

Comparing jsr166/src/test/tck/AtomicReferenceArrayTest.java (file contents):
Revision 1.13 by jsr166, Mon Nov 16 05:30:07 2009 UTC vs.
Revision 1.14 by jsr166, Tue Nov 17 02:50:57 2009 UTC

# Line 36 | Line 36 | public class AtomicReferenceArrayTest ex
36          try {
37              Integer[] a = null;
38              AtomicReferenceArray<Integer> ai = new AtomicReferenceArray<Integer>(a);
39 +            shouldThrow();
40          } catch (NullPointerException success) {
40        } catch (Exception ex) {
41            unexpectedException();
42        }
41      }
42  
43      /**
# Line 61 | Line 59 | public class AtomicReferenceArrayTest ex
59          AtomicReferenceArray<Integer> ai = new AtomicReferenceArray<Integer>(SIZE);
60          try {
61              ai.get(SIZE);
62 +            shouldThrow();
63          } catch (IndexOutOfBoundsException success) {
64          }
65          try {
66              ai.get(-1);
67 +            shouldThrow();
68          } catch (IndexOutOfBoundsException success) {
69          }
70          try {
71              ai.set(SIZE, null);
72 +            shouldThrow();
73          } catch (IndexOutOfBoundsException success) {
74          }
75          try {
76              ai.set(-1, null);
77 +            shouldThrow();
78          } catch (IndexOutOfBoundsException success) {
79          }
80      }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines