### Question:
BitSet implements Serializable, Cloneable { public void set(int index) { bits[index >>> 6] |= 1L << (index & 0x3F); } BitSet(int numBits); private  BitSet(long[] bits); boolean get(int index); void set(int index); void set(int from, int to); void clear(int index); void clear(); int cardinality(); int nextSetBit(int index); @Override BitSet clone(); @Override int hashCode(); @Override boolean equals(Object o); @Override String toString();  }### Answer:
@Test(expected = ArrayIndexOutOfBoundsException.class) public void testBounds1() { BitSet bitSet = new BitSet(NUM_BITS); bitSet.set(1000); }
@Test(expected = ArrayIndexOutOfBoundsException.class) public void testBounds2() { BitSet bitSet = new BitSet(NUM_BITS); bitSet.set(-1); }