annotate src/testdir/test72.in @ 2821:3d1a3aa0240c v7.3.186

updated for version 7.3.186 Problem: When 'clipboard' contains "unnamed" or "unnamedplus" the value of v:register is wrong for operators without a specific register. Solution: Adjust the register according to 'clipboard'. (Ingo Karkat)
author Bram Moolenaar <bram@vim.org>
date Tue, 10 May 2011 16:12:45 +0200
parents dcb3ab4587b4
children c4898d6d73a2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2232
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
1 Tests for undo file.
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
2 Since this script is sourced we need to explicitly break changes up in
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
3 undo-able pieces. Do that by setting 'undolevels'.
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
4
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
5 STARTTEST
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
6 :so small.vim
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
7 :"
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
8 :" Test 'undofile': first a simple one-line change.
2504
dcb3ab4587b4 Set 'visualbell' in test 72 to avoid a beep.
Bram Moolenaar <bram@vim.org>
parents: 2459
diff changeset
9 :set nocompatible viminfo+=nviminfo visualbell
2456
2876ac15b8c8 Avoid that running tests changes viminfo.
Bram Moolenaar <bram@vim.org>
parents: 2438
diff changeset
10 :set ul=100 undofile nomore
2232
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
11 :e! Xtestfile
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
12 ggdGithis is one line:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
13 :s/one/ONE/
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
14 :set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
15 :w
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
16 :bwipe!
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
17 :e Xtestfile
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
18 u:.w! test.out
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
19 :"
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
20 :" Test 'undofile', change in original file fails check
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
21 :set noundofile
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
22 :e! Xtestfile
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
23 :s/line/Line/
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
24 :w
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
25 :set undofile
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
26 :bwipe!
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
27 :e Xtestfile
2459
64df5d008ccb Fix: test 69 didn't work on MS-Windows. Test 72 beeped too often.
Bram Moolenaar <bram@vim.org>
parents: 2456
diff changeset
28 :" TODO: this beeps
2232
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
29 u:.w >>test.out
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
30 :"
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
31 :" Test 'undofile', add 10 lines, delete 6 lines, undo 3
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
32 :set undofile
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
33 ggdGione
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
34 two
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
35 three
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
36 four
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
37 five
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
38 six
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
39 seven
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
40 eight
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
41 nine
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
42 ten:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
43 3Gdd:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
44 dd:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
45 dd:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
46 dd:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
47 dd:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
48 dd:set ul=100
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
49 :w
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
50 :bwipe!
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
51 :e Xtestfile
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
52 uuu:w >>test.out
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
53 :"
2438
9614fe67034c Fix test 72 not setting encryption method. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents: 2267
diff changeset
54 :" And now with encryption, cryptmethod=zip
2239
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
55 :e! Xtestfile
2438
9614fe67034c Fix test 72 not setting encryption method. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents: 2267
diff changeset
56 :set undofile cm=zip
2459
64df5d008ccb Fix: test 69 didn't work on MS-Windows. Test 72 beeped too often.
Bram Moolenaar <bram@vim.org>
parents: 2456
diff changeset
57 ggdGimonday
2239
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
58 tuesday
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
59 wednesday
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
60 thursday
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
61 friday:set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
62 kkkdd:set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
63 dd:set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
64 dd:set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
65 :X
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
66 foobar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
67 foobar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
68 :w!
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
69 :bwipe!
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
70 :e Xtestfile
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
71 foobar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
72 :set key=
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
73 uu:w >>test.out
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
74 :"
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
75 :"
2438
9614fe67034c Fix test 72 not setting encryption method. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents: 2267
diff changeset
76 :" With encryption, cryptmethod=blowfish
2239
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
77 :e! Xtestfile
2438
9614fe67034c Fix test 72 not setting encryption method. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents: 2267
diff changeset
78 :set undofile cm=blowfish
2459
64df5d008ccb Fix: test 69 didn't work on MS-Windows. Test 72 beeped too often.
Bram Moolenaar <bram@vim.org>
parents: 2456
diff changeset
79 ggdGijan
2239
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
80 feb
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
81 mar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
82 apr
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
83 jun:set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
84 kk0ifoo :set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
85 dd:set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
86 ibar :set ul=100
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
87 :X
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
88 foobar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
89 foobar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
90 :w!
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
91 :bwipe!
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
92 :e Xtestfile
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
93 foobar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
94 :set key=
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
95 /bar
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
96 :.w >>test.out
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
97 u:.w >>test.out
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
98 u:.w >>test.out
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
99 u:.w >>test.out
732cb7b31956 Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents: 2232
diff changeset
100 :"
2232
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
101 :" Rename the undo file so that it gets cleaned up.
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
102 :call rename(".Xtestfile.un~", "Xtestundo")
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
103 :qa!
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
104 ENDTEST
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
105
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
106 1111 -----
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
107 2222 -----
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
108
2e6906bbc5f4 A few more fixes for undo file. Split test in two parts so that it doesn't
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
109 123456789