annotate src/testdir/test_help.vim @ 12383:1890536614ea v8.0.1071

patch 8.0.1071: putty-color and cygwin-color are not recognized commit https://github.com/vim/vim/commit/c6da01a5b8efe9ca4931074c0cf2189d357707a2 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Sep 7 22:37:36 2017 +0200 patch 8.0.1071: putty-color and cygwin-color are not recognized Problem: $TERM names starting with "putty" and "cygwin" are likely to have a dark background, but are not recognized. Solution: Only check the first few characters of $TERM to match "putty" or "cygwin". (Christian Brabandt)
author Christian Brabandt <cb@256bit.org>
date Thu, 07 Sep 2017 22:45:04 +0200
parents 55cf556d8ce1
children e1deb00ffc27
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
10883
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
1 " Tests for :help
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
2
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
3 func Test_help_restore_snapshot()
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
4 help
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
5 set buftype=
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
6 help
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
7 edit x
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
8 help
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
9 helpclose
cb71a5468aca patch 8.0.0331: restoring help snapshot accesses freed memory
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
10 endfunc
11167
260100346566 patch 8.0.0470: not enough testing for help commands
Christian Brabandt <cb@256bit.org>
parents: 10883
diff changeset
11
260100346566 patch 8.0.0470: not enough testing for help commands
Christian Brabandt <cb@256bit.org>
parents: 10883
diff changeset
12 func Test_help_errors()
260100346566 patch 8.0.0470: not enough testing for help commands
Christian Brabandt <cb@256bit.org>
parents: 10883
diff changeset
13 call assert_fails('help doesnotexist', 'E149:')
260100346566 patch 8.0.0470: not enough testing for help commands
Christian Brabandt <cb@256bit.org>
parents: 10883
diff changeset
14 call assert_fails('help!', 'E478:')
12236
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
15
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
16 new
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
17 set keywordprg=:help
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
18 call setline(1, " ")
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
19 call assert_fails('normal VK', 'E349:')
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
20 bwipe!
11167
260100346566 patch 8.0.0470: not enough testing for help commands
Christian Brabandt <cb@256bit.org>
parents: 10883
diff changeset
21 endfunc
12236
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
22
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
23 func Test_help_keyword()
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
24 new
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
25 set keywordprg=:help
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
26 call setline(1, " Visual ")
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
27 normal VK
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
28 call assert_match('^Visual mode', getline('.'))
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
29 call assert_equal('help', &ft)
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
30 close
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
31 bwipe!
55cf556d8ce1 patch 8.0.0998: strange error when using K while only spaces are selected
Christian Brabandt <cb@256bit.org>
parents: 11167
diff changeset
32 endfunc