565758596061626364
// Check #4. edit.undo(); harness.check(edit.canRedo()); // Check #5. edit.die(); harness.check(!edit.canRedo()); } }
505152535455565758
// Check #3. harness.check(!edit.replaceEdit(new AbstractUndoableEdit())); // Check #4. edit.die(); harness.check(!edit.replaceEdit(edit)); } }
7475767778798081828384
} harness.check(caught instanceof CannotUndoException); // Check #3: Exception for dead edit. AbstractUndoableEdit aue = new AbstractUndoableEdit(); aue.die(); try { aue.undo(); caught = null; }
// Check #3. harness.check(!edit.addEdit(new AbstractUndoableEdit())); // Check #4. edit.die(); harness.check(!edit.addEdit(edit)); } }
7677787980818283848586
harness.check(caught instanceof CannotRedoException); // Check #3: Exception for dead edit. AbstractUndoableEdit aue = new AbstractUndoableEdit(); aue.undo(); aue.die(); try { aue.redo(); caught = null; }
525354555657585960
// Check #3. edit.redo(); harness.check(edit.canUndo()); // Check #4. edit.die(); harness.check(!edit.canUndo()); } }