private void UndoCommand(IInputHandler argsHandler) { if (_document.CanUndo()) { _document.Undo(); } else { _out.WriteLine("Can't Undo"); } }
public void Execute(string commandData, TextWriter textWriter) { if (_document.CanUndo()) { _document.Undo(); } else { textWriter.WriteLine(Constants.IMPOSSIBLE_TO_UNDO); } }
public void CanUndo_WithEmptyHistory_ShouldReturnFalse() { Assert.IsFalse(_document.CanUndo()); }