refactoring TestUndoRedoStack