tx.commit();
fail("RollbackException should have been thrown from the externalizer");
}catch (RollbackException rollBackException) {
Throwable[] throwables = rollBackException.getNestedThrowables();
assertTrue(throwables[0] instanceof PersistenceException);
PersistenceException persistentException = (PersistenceException) throwables[0];
assertNotNull(persistentException);
assertEquals(1, persistentException.getNestedThrowables().length);
}
}