Simple tryout
int i = 0;
while (it.hasNext()) {
assertEquals(TESTDATA[i++], it.next());
}
// XXX read up on writing JUnit tests that should throw exceptions
try {
it.next(); // EXPECT RUNTIME ERROR
System.err.println("ERROR - DID NOT GET EXPECTED EXCEPTION");
} catch (IndexOutOfBoundsException e) {
System.err.println("Got expected exception -- OK!");
}