forked from aniani/vim
Included patch for persistent undo. Lots of changes and added test.
This commit is contained in:
@@ -69,7 +69,7 @@ test1.out: test1.in
|
||||
fi \
|
||||
else echo $* NO OUTPUT >>test.log; \
|
||||
fi"
|
||||
#-rm -rf X* test.ok viminfo
|
||||
-rm -rf X* test.ok viminfo
|
||||
|
||||
test49.out: test49.vim
|
||||
|
||||
|
||||
@@ -50,6 +50,53 @@ obbbbu:.w >>test.out
|
||||
obbbb:set ul=100
|
||||
:undojoin
|
||||
occccu:.w >>test.out
|
||||
:"
|
||||
:" Test 'undofile': first a simple one-line change.
|
||||
:set nocp ul=100 undofile
|
||||
:e! Xtestfile
|
||||
ggdGithis is one line:set ul=100
|
||||
:s/one/ONE/
|
||||
:set ul=100
|
||||
:w
|
||||
:bwipe!
|
||||
:e Xtestfile
|
||||
u:.w >>test.out
|
||||
:"
|
||||
:" Test 'undofile', change in original file fails check
|
||||
:set noundofile
|
||||
:e! Xtestfile
|
||||
:s/line/Line/
|
||||
:w
|
||||
:set undofile
|
||||
:bwipe!
|
||||
:e Xtestfile
|
||||
u:.w >>test.out
|
||||
:"
|
||||
:" Test 'undofile', add 10 lines, delete 6 lines, undo 3
|
||||
:set undofile
|
||||
ggdGione
|
||||
two
|
||||
three
|
||||
four
|
||||
five
|
||||
six
|
||||
seven
|
||||
eight
|
||||
nine
|
||||
ten:set ul=100
|
||||
3Gdd:set ul=100
|
||||
dd:set ul=100
|
||||
dd:set ul=100
|
||||
dd:set ul=100
|
||||
dd:set ul=100
|
||||
dd:set ul=100
|
||||
:w
|
||||
:bwipe!
|
||||
:e Xtestfile
|
||||
uuu:w >>test.out
|
||||
:"
|
||||
:" Rename the undo file so that it gets cleaned up.
|
||||
:call rename(".Xtestfile.un~", "Xtestundo")
|
||||
:qa!
|
||||
ENDTEST
|
||||
|
||||
|
||||
@@ -22,3 +22,12 @@
|
||||
123456abc
|
||||
aaaa
|
||||
aaaa
|
||||
this is one line
|
||||
this is ONE Line
|
||||
one
|
||||
two
|
||||
six
|
||||
seven
|
||||
eight
|
||||
nine
|
||||
ten
|
||||
|
||||
Reference in New Issue
Block a user