Mercurial > vim
annotate src/testdir/test53.in @ 8847:470ea7526cc6 v7.4.1711
commit https://github.com/vim/vim/commit/a742e084b677f76c67e9e52c4f9fb9ab24002e20
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Apr 5 21:10:38 2016 +0200
patch 7.4.1711
Problem: When using try/catch in 'statusline' it is still considered an
error and the status line will be disabled.
Solution: Check did_emsg instead of called_emsg. (haya14busa, closes https://github.com/vim/vim/issues/729)
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Tue, 05 Apr 2016 21:15:05 +0200 |
parents | 950e24f26ef8 |
children | 847518911c0b |
rev | line source |
---|---|
853 | 1 Tests for string and html text objects. vim: set ft=vim : |
12 | 2 |
19 | 3 Note that the end-of-line moves the cursor to the next test line. |
4 | |
5 Also test match() and matchstr() | |
6 | |
5676 | 7 Also test the gn command and repeating it. |
8 | |
12 | 9 STARTTEST |
10 :so small.vim | |
11 /^start:/ | |
12 da" | |
13 0va'a'rx | |
14 02f`da` | |
15 0fXdi" | |
16 03f'vi'ry | |
17 :set quoteescape=+*- | |
18 di` | |
19 $F"va"oha"i"rz | |
853 | 20 :" |
21 /^<begin | |
22 jfXdit | |
23 0fXdit | |
24 fXdat | |
25 0fXdat | |
6661 | 26 dit |
853 | 27 :" |
28 :put =matchstr(\"abcd\", \".\", 0, 2) " b | |
19 | 29 :put =matchstr(\"abcd\", \"..\", 0, 2) " bc |
30 :put =matchstr(\"abcd\", \".\", 2, 0) " c (zero and negative -> first match) | |
31 :put =matchstr(\"abcd\", \".\", 0, -1) " a | |
32 :put =match(\"abcd\", \".\", 0, 5) " -1 | |
33 :put =match(\"abcd\", \".\", 0, -1) " 0 | |
5676 | 34 :put =match('abc', '.', 0, 1) " 0 |
35 :put =match('abc', '.', 0, 2) " 1 | |
36 :put =match('abc', '.', 0, 3) " 2 | |
37 :put =match('abc', '.', 0, 4) " -1 | |
38 :put =match('abc', '.', 1, 1) " 1 | |
39 :put =match('abc', '.', 2, 1) " 2 | |
40 :put =match('abc', '.', 3, 1) " -1 | |
41 :put =match('abc', '$', 0, 1) " 3 | |
42 :put =match('abc', '$', 0, 2) " -1 | |
43 :put =match('abc', '$', 1, 1) " 3 | |
44 :put =match('abc', '$', 2, 1) " 3 | |
45 :put =match('abc', '$', 3, 1) " 3 | |
46 :put =match('abc', '$', 4, 1) " -1 | |
47 :put =match('abc', '\zs', 0, 1) " 0 | |
48 :put =match('abc', '\zs', 0, 2) " 1 | |
49 :put =match('abc', '\zs', 0, 3) " 2 | |
50 :put =match('abc', '\zs', 0, 4) " 3 | |
51 :put =match('abc', '\zs', 0, 5) " -1 | |
52 :put =match('abc', '\zs', 1, 1) " 1 | |
53 :put =match('abc', '\zs', 2, 1) " 2 | |
54 :put =match('abc', '\zs', 3, 1) " 3 | |
55 :put =match('abc', '\zs', 4, 1) " -1 | |
3701 | 56 /^foobar |
57 gncsearchmatch/one\_s*two\_s | |
58 :1 | |
59 gnd | |
60 /[a]bcdx | |
61 :1 | |
3774 | 62 2gnd/join |
63 /$ | |
64 0gnd | |
65 /\>\zs | |
66 0gnd/^ | |
67 gnd$h/\zs | |
3778 | 68 gnd/[u]niquepattern/s |
69 vlgnd | |
3857 | 70 /mother |
71 :set selection=exclusive | |
5064
8875401008da
updated for version 7.3.1275
Bram Moolenaar <bram@vim.org>
parents:
3857
diff
changeset
|
72 $cgNmongoose/i |
8875401008da
updated for version 7.3.1275
Bram Moolenaar <bram@vim.org>
parents:
3857
diff
changeset
|
73 cgnj |
5398 | 74 :" Make sure there is no other match y uppercase. |
75 /x59 | |
76 gggnd | |
5676 | 77 :" test repeating dgn |
78 /^Johnny | |
79 ggdgn. | |
80 :" test repeating gUgn | |
81 /^Depp | |
82 gggUgn. | |
6443 | 83 gg/a:0\@!\zs\d\+ |
84 nygnop | |
12 | 85 :/^start:/,/^end:/wq! test.out |
86 ENDTEST | |
87 | |
88 start: "wo\"rd\\" foo | |
89 'foo' 'bar' 'piep' | |
90 bla bla `quote` blah | |
91 out " in "noXno" | |
92 "'" 'blah' rep 'buh' | |
93 bla `s*`d-`+++`l**` b`la | |
94 voo "nah" sdf " asdf" sdf " sdf" sd | |
853 | 95 |
96 <begin> | |
97 -<b>asdf<i>Xasdf</i>asdf</b>- | |
98 -<b>asdX<i>a<i />sdf</i>asdf</b>- | |
99 -<b>asdf<i>Xasdf</i>asdf</b>- | |
100 -<b>asdX<i>as<b />df</i>asdf</b>- | |
6661 | 101 -<b> |
102 innertext object | |
103 </b> | |
853 | 104 </begin> |
3701 | 105 SEARCH: |
106 foobar | |
107 one | |
108 two | |
109 abcdx | abcdx | abcdx | |
3774 | 110 join |
111 lines | |
112 zero width pattern | |
113 delete first and last chars | |
3778 | 114 uniquepattern uniquepattern |
3857 | 115 my very excellent mother just served us nachos |
5064
8875401008da
updated for version 7.3.1275
Bram Moolenaar <bram@vim.org>
parents:
3857
diff
changeset
|
116 for (i=0; i<=10; i++) |
6443 | 117 a:10 |
118 | |
119 a:1 | |
120 | |
121 a:20 | |
5398 | 122 Y |
123 text | |
124 Y | |
5676 | 125 --1 |
126 Johnny | |
127 --2 | |
128 Johnny | |
129 --3 | |
130 Depp | |
131 --4 | |
132 Depp | |
133 --5 | |
12 | 134 end: |