String[] theFinalStates1 = init1;
Exception[] theExceptions = { null, null, null, null, null, null, null,
null };
TransactionRolledbackException aTransactionRolledbackException;
int loopCount = init1.length;
for (int i = 0; i < loopCount; i++) {
try {
aTransactionRolledbackException = new TransactionRolledbackException(
init1[i]);
if (theExceptions[i] != null) {
fail();
}
assertEquals(i + " Final state mismatch",
aTransactionRolledbackException.getMessage(),
theFinalStates1[i]);
} catch (Exception e) {
if (theExceptions[i] == null) {
fail(i + "Unexpected exception");