private void test12() {
try {
boolean allActionsUndone;
Session session = getDomainModel().getSession();
Transaction transaction = new Transaction(session);
Comments comments = getComments();
Comment firstComment = (Comment) comments.first();
Comment secondComment = (Comment) comments.next(firstComment);
EntitiesAction action1 = new RemoveAction(transaction);
action1.setEntities(comments);
action1.setEntity(firstComment);
EntitiesAction action2 = new RemoveAction(transaction);
action2.setEntities(comments);
action2.setEntity(secondComment);
transaction.execute();
allActionsUndone = transaction.undo();
log.info("Undone Transaction: " + allActionsUndone);
} catch (ActionException ae) {
log.info("Transaction problem: " + ae.getMessage());
}
}