Mercurial > vim
annotate src/testdir/test72.in @ 15380:f62d6bd18a49 v8.1.0698
patch 8.1.0698: clearing the window is used too often
commit https://github.com/vim/vim/commit/bf3250a8ad39797e3ccdac82d20c6f19533419e4
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Jan 6 17:25:29 2019 +0100
patch 8.1.0698: clearing the window is used too often
Problem: Clearing the window is used too often, causing the command line
to be cleared when opening a tab. (Miroslav Ko?k?r)
Solution: Use NOT_VALID instead of CLEAR. (suggested by Jason Franklin,
closes #630) Also do this for a few other places where clearing
the screen isn't really needed.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 06 Jan 2019 17:30:05 +0100 |
parents | ae45d497868f |
children |
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 |
11091
ae45d497868f
patch 8.0.0433: beeps when running tests
Christian Brabandt <cb@256bit.org>
parents:
6334
diff
changeset
|
7 :set belloff=all |
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
|
8 :" |
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
|
9 :" 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
|
10 :set nocompatible viminfo+=nviminfo visualbell |
2456
2876ac15b8c8
Avoid that running tests changes viminfo.
Bram Moolenaar <bram@vim.org>
parents:
2438
diff
changeset
|
11 :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
|
12 :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
|
13 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
|
14 :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
|
15 :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
|
16 :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
|
17 :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
|
18 :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
|
19 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
|
20 :" |
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 :" 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
|
22 :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
|
23 :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
|
24 :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
|
25 :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
|
26 :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
|
27 :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
|
28 :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
|
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 :" |
3246 | 54 :" Test that reading the undofiles when setting undofile works |
55 :set noundofile ul=0 | |
56 i | |
57 u:e! Xtestfile | |
58 :set undofile ul=100 | |
59 uuuuuu:w >>test.out | |
2438
9614fe67034c
Fix test 72 not setting encryption method. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents:
2267
diff
changeset
|
60 :" 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
|
61 :e! Xtestfile |
2438
9614fe67034c
Fix test 72 not setting encryption method. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents:
2267
diff
changeset
|
62 :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
|
63 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
|
64 tuesday |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
65 wednesday |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
66 thursday |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
67 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
|
68 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
|
69 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
|
70 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
|
71 :X |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
72 foobar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
73 foobar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
74 :w! |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
75 :bwipe! |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
76 :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
|
77 foobar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
78 :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
|
79 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
|
80 :" |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
81 :" |
2438
9614fe67034c
Fix test 72 not setting encryption method. (Dominique Pelle)
Bram Moolenaar <bram@vim.org>
parents:
2267
diff
changeset
|
82 :" 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
|
83 :e! Xtestfile |
6122 | 84 rubbish |
6334 | 85 :set undofile cm=blowfish ff& |
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
|
86 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
|
87 feb |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
88 mar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
89 apr |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
90 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
|
91 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
|
92 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
|
93 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
|
94 :X |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
95 foobar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
96 foobar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
97 :w! |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
98 :bwipe! |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
99 :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
|
100 foobar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
101 :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
|
102 /bar |
732cb7b31956
Crypt the text in the undo file if the file itself is crypted.
Bram Moolenaar <bram@vim.org>
parents:
2232
diff
changeset
|
103 :.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
|
104 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
|
105 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
|
106 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
|
107 :" |
6122 | 108 :" With encryption, cryptmethod=blowfish2 |
109 :e! Xtestfile | |
110 rubbish | |
6334 | 111 :set undofile cm=blowfish2 ff& |
6122 | 112 ggdGijan |
113 feb | |
114 mar | |
115 apr | |
116 jun:set ul=100 | |
117 kk0ifoo :set ul=100 | |
118 dd:set ul=100 | |
119 ibar :set ul=100 | |
120 :X | |
121 foo2bar | |
122 foo2bar | |
123 :w! | |
124 :bwipe! | |
125 :e Xtestfile | |
126 foo2bar | |
127 :set key= | |
128 /bar | |
129 :.w >>test.out | |
130 u:.w >>test.out | |
131 u:.w >>test.out | |
132 u:.w >>test.out | |
133 :" | |
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
|
134 :" Rename the undo file so that it gets cleaned up. |
5704 | 135 :if has("vms") |
136 : call rename("_un_Xtestfile", "Xtestundo") | |
137 :else | |
138 : call rename(".Xtestfile.un~", "Xtestundo") | |
139 :endif | |
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
|
140 :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
|
141 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
|
142 |
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
|
143 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
|
144 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
|
145 |
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
|
146 123456789 |