]> granicus.if.org Git - vim/commitdiff
patch 8.1.1544: some balloon tests don't run when they can v8.1.1544
authorBram Moolenaar <Bram@vim.org>
Sat, 15 Jun 2019 15:58:09 +0000 (17:58 +0200)
committerBram Moolenaar <Bram@vim.org>
Sat, 15 Jun 2019 15:58:09 +0000 (17:58 +0200)
Problem:    Some balloon tests don't run when they can.
Solution:   Split GUI balloon tests off into a separate file. (Ozaki Kiichi,
            closes #4538)  Change the feature check into a command for
            consistency.

56 files changed:
Filelist
src/testdir/Make_all.mak
src/testdir/check.vim [new file with mode: 0644]
src/testdir/test_arabic.vim
src/testdir/test_balloon.vim
src/testdir/test_balloon_gui.vim [new file with mode: 0644]
src/testdir/test_crypt.vim
src/testdir/test_cscope.vim
src/testdir/test_digraph.vim
src/testdir/test_float_func.vim
src/testdir/test_gui.vim
src/testdir/test_gui_init.vim
src/testdir/test_history.vim
src/testdir/test_langmap.vim
src/testdir/test_listlbr.vim
src/testdir/test_listlbr_utf8.vim
src/testdir/test_lua.vim
src/testdir/test_makeencoding.vim
src/testdir/test_matchadd_conceal.vim
src/testdir/test_matchadd_conceal_utf8.vim
src/testdir/test_memory_usage.vim
src/testdir/test_menu.vim
src/testdir/test_mksession.vim
src/testdir/test_mksession_utf8.vim
src/testdir/test_netbeans.vim
src/testdir/test_paste.vim
src/testdir/test_perl.vim
src/testdir/test_popupwin.vim
src/testdir/test_profile.vim
src/testdir/test_prompt_buffer.vim
src/testdir/test_python2.vim
src/testdir/test_python3.vim
src/testdir/test_pyx2.vim
src/testdir/test_pyx3.vim
src/testdir/test_quickfix.vim
src/testdir/test_quotestar.vim
src/testdir/test_reltime.vim
src/testdir/test_ruby.vim
src/testdir/test_sha256.vim
src/testdir/test_shortpathname.vim
src/testdir/test_signals.vim
src/testdir/test_signs.vim
src/testdir/test_spell.vim
src/testdir/test_syntax.vim
src/testdir/test_tcl.vim
src/testdir/test_termcodes.vim
src/testdir/test_terminal.vim
src/testdir/test_terminal_fail.vim
src/testdir/test_textobjects.vim
src/testdir/test_textprop.vim
src/testdir/test_timers.vim
src/testdir/test_vartabs.vim
src/testdir/test_winbar.vim
src/testdir/test_windows_home.vim
src/testdir/test_xxd.vim
src/version.c

index 99e10048ff72178782c5ed8766e313cefd6aa549..63088a69128c5bba1ad7c0275c4ce86e45a55843 100644 (file)
--- a/Filelist
+++ b/Filelist
@@ -120,6 +120,7 @@ SRC_ALL =   \
                src/testdir/sautest/autoload/*.vim \
                src/testdir/runtest.vim \
                src/testdir/summarize.vim \
+               src/testdir/check.vim \
                src/testdir/shared.vim \
                src/testdir/screendump.vim \
                src/testdir/view_util.vim \
index 9e551c1e1c7ad980dabd85e638d3968a847b3e90..eb014a95c2cdb2beef5532f0a73d5fad321cda5e 100644 (file)
@@ -65,6 +65,7 @@ NEW_TESTS = \
        test_backspace_opt \
        test_backup \
        test_balloon \
+       test_balloon_gui \
        test_behave \
        test_blob \
        test_blockedit \
@@ -297,6 +298,7 @@ NEW_TESTS_RES = \
        test_autoload.res \
        test_backspace_opt.res \
        test_balloon.res \
+       test_balloon_gui.res \
        test_blob.res \
        test_blockedit.res \
        test_breakindent.res \
diff --git a/src/testdir/check.vim b/src/testdir/check.vim
new file mode 100644 (file)
index 0000000..7f37f1c
--- /dev/null
@@ -0,0 +1,23 @@
+" Command to check for the presence of a feature.
+command -nargs=1 CheckFeature call CheckFeature(<f-args>)
+func CheckFeature(name)
+  if !has(a:name)
+    throw 'Skipped: ' .. a:name .. ' feature missing'
+  endif
+endfunc
+
+" Command to check for the presence of a working option.
+command -nargs=1 CheckOption call CheckOption(<f-args>)
+func CheckOption(name)
+  if !exists('+' .. a:name)
+    throw 'Skipped: ' .. a:name .. ' option not supported'
+  endif
+endfunc
+
+" Command to check for the presence of a function.
+command -nargs=1 CheckFunction call CheckFunction(<f-args>)
+func CheckFunction(name)
+  if !exists('*' .. a:name)
+    throw 'Skipped: ' .. a:name .. ' function missing'
+  endif
+endfunc
index 450c6f98f5a63867038374c68b368b3ff1dd190b..b679ec45204b431f6c200b7b116689b41f8ffa97 100644 (file)
@@ -2,9 +2,8 @@
 " NOTE: This just checks if the code works. If you know Arabic please add
 " functional tests that check the shaping works with real text.
 
-if !has('arabic')
-  throw 'Skipped: arabic feature missing'
-endif
+source check.vim
+CheckFeature arabic
 
 source view_util.vim
 
index abf7d6944e6dad96a435f16e70e314cdac7c98bf..793eb3a571e2e3ea736d469fbfe57ca0494f6331 100644 (file)
@@ -1,11 +1,12 @@
 " Tests for 'balloonevalterm'.
+" A few tests only work in the terminal.
 
-if !has('balloon_eval_term')
-  throw 'Skipped: balloon_eval_term feature missing'
+if has('gui_running')
+  throw 'Skipped: only work in the terminal'
 endif
 
-" A few tests only work in the terminal.
-if !has('gui_running')
+source check.vim
+CheckFeature balloon_eval_term
 
 source screendump.vim
 if !CanRunVimInTerminal()
@@ -56,24 +57,3 @@ func Test_balloon_eval_term_visual()
   call StopVimInTerminal(buf)
   call delete('XTest_beval_visual')
 endfunc
-
-endif
-
-" Tests that only work in the GUI
-if has('gui_running')
-
-func Test_balloon_show_gui()
-  let msg = 'this this this this'
-  call balloon_show(msg)
-  call assert_equal(msg, balloon_gettext())
-  sleep 10m
-  call balloon_show('')
-
-  let msg = 'that that'
-  call balloon_show(msg)
-  call assert_equal(msg, balloon_gettext())
-  sleep 10m
-  call balloon_show('')
-endfunc
-
-endif
diff --git a/src/testdir/test_balloon_gui.vim b/src/testdir/test_balloon_gui.vim
new file mode 100644 (file)
index 0000000..fd01309
--- /dev/null
@@ -0,0 +1,22 @@
+" Tests for 'ballooneval' in the GUI.
+
+if !has('gui_running')
+  throw 'Skipped: only works in the GUI'
+endif
+
+source check.vim
+CheckFeature balloon_eval
+
+func Test_balloon_show_gui()
+  let msg = 'this this this this'
+  call balloon_show(msg)
+  call assert_equal(msg, balloon_gettext())
+  sleep 10m
+  call balloon_show('')
+
+  let msg = 'that that'
+  call balloon_show(msg)
+  call assert_equal(msg, balloon_gettext())
+  sleep 10m
+  call balloon_show('')
+endfunc
index db100991ab5f31a23d32a84788ff844860b46467..ab62d84708cd7b3d4fe7e920ab2698e2ddf6ac00 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for encryption.
 
-if !has('cryptv')
-  throw 'Skipped, encryption feature missing'
-endif
+source check.vim
+CheckFeature cryptv
 
 func Common_head_only(text)
   " This was crashing Vim
index a3fcbd77b65bf29f1819296377c23b30787d87ce..c776be113871ed2c28c87a6869d7c9d20293486d 100644 (file)
@@ -1,10 +1,11 @@
 " Test for cscope commands.
 
-if !has('cscope') || !has('quickfix')
-  throw 'Skipped, cscope or quickfix feature missing'
-endif
+source check.vim
+CheckFeature cscope
+CheckFeature quickfix
+
 if !executable('cscope')
-  throw 'Skipped, cscope program missing'
+  throw 'Skipped: cscope program missing'
 endif
 
 func CscopeSetupOrClean(setup)
index 92d4e479a710ab1272c29f1b4ee9fc0b688a7548..6435c86fa4927ba1c065db0634db5eef7efa7608 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for digraphs
 
-if !has("digraphs")
-  throw 'Skipped, digraphs feature missing'
-endif
+source check.vim
+CheckFeature digraphs
 
 func Put_Dig(chars)
   exe "norm! o\<c-k>".a:chars
index 6340b538f5a0f679f49f99d587d66df788241d80..f407f40eb08560f9f8f12401792b5ea548a0651e 100644 (file)
@@ -1,8 +1,7 @@
 " test float functions
 
-if !has('float')
-  throw 'Skipped, float feature missing'
-end
+source check.vim
+CheckFeature float
 
 func Test_abs()
   call assert_equal('1.23', string(abs(1.23)))
index d030a6ae6ae3f0bb37683722ab1e02e1697a6c10..7f94e6a8d94da24646c00b1719276a9f997ebf94 100644 (file)
@@ -2,7 +2,7 @@
 
 source shared.vim
 if !CanRunGui()
-  throw 'Skipped, cannot run GUI'
+  throw 'Skipped: cannot run GUI'
 endif
 
 source setup_gui.vim
index a8eefa56b9aa0492bf571717f478e9bc0874039e..ecc8fc9efe5067fd59a84b667a212bae1d2f435c 100644 (file)
@@ -3,7 +3,7 @@
 
 source shared.vim
 if !CanRunGui()
-  throw 'Skipped, cannot run GUI'
+  throw 'Skipped: cannot run GUI'
 endif
 
 source setup_gui.vim
index 4b464137bbfc2a1e55879402c72ef16b817e7877..215fc0a55a76953053a64fed4167f90562acdd38 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for the history functions
 
-if !has('cmdline_hist')
-  throw 'Skipped, cmdline_hist feature missing'
-endif
+source check.vim
+CheckFeature cmdline_hist
 
 set history=7
 
index 4b260f8480120d897cc3ed42c699c7fbec8f9a48..420ff0fe8a4b1bb1c7065218e48c597b65e6a4c3 100644 (file)
@@ -1,8 +1,7 @@
 " tests for 'langmap'
 
-if !has('langmap')
-  throw 'Skipped, langmap feature missing'
-endif
+source check.vim
+CheckFeature langmap
 
 func Test_langmap()
   new
index 5af4133ec8edde1aa39c36b28083933aa19ca613..a2abc93b7e654dd424a8b66d09ab8f17698c5d15 100644 (file)
@@ -3,12 +3,9 @@
 set encoding=latin1
 scriptencoding latin1
 
-if !exists("+linebreak")
-  throw 'Skipped, linebreak option missing'
-endif
-if !has("conceal")
-  throw 'Skipped, conceal feature missing'
-endif
+source check.vim
+CheckOption linebreak
+CheckFeature conceal
 
 source view_util.vim
 
index 1154d6626bab62816c6139be92cea357fc58b3ad..ddce6f36d6c35708d0f3a8f5dc75e75e69e0dd87 100644 (file)
@@ -3,15 +3,10 @@
 set encoding=utf-8
 scriptencoding utf-8
 
-if !exists("+linebreak")
-  throw 'Skipped, linebreak option missing'
-endif
-if !has("conceal")
-  throw 'Skipped, conceal feature missing'
-endif
-if !has("signs")
-  throw 'Skipped, signs feature missing'
-endif
+source check.vim
+CheckOption linebreak
+CheckFeature conceal
+CheckFeature signs
 
 source view_util.vim
 
index 5d2f088e3f9d8591085032700670607f95d3a1c8..65753dc4a6f8357bc7cf3e88327b87f66097cad8 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for Lua.
 
-if !has('lua')
-  throw 'Skipped, lua feature missing'
-endif
+source check.vim
+CheckFeature lua
 
 func TearDown()
   " Run garbage collection after each test to exercise luaV_setref().
index 6de3c706f38d0d16035652a69e260d7af26f3d47..09d36eac9a688aa723eebd64f1408dc343002230 100644 (file)
@@ -4,7 +4,7 @@ source shared.vim
 
 let s:python = PythonProg()
 if s:python == ''
-  throw 'Skipped, python program missing'
+  throw 'Skipped: python program missing'
 endif
 
 let s:script = 'test_makeencoding.py'
index a7c8b06f539f92eeb46bf42d1a9d8b9cd6d98d11..6684378f665e18d82b476d56e151ba992520c887 100644 (file)
@@ -1,8 +1,7 @@
 " Test for matchadd() and conceal feature
 
-if !has('conceal')
-  throw 'Skipped, conceal feature missing'
-endif
+source check.vim
+CheckFeature conceal
 
 if !has('gui_running') && has('unix')
   set term=ansi
index fb275777da42a93499ae18f461742f4d056139c4..98ed2cbe604e86065d425f5ae1d955e796f34292 100644 (file)
@@ -1,8 +1,7 @@
 " Test for matchadd() and conceal feature using utf-8.
 
-if !has('conceal')
-  throw 'Skipped, conceal feature missing'
-endif
+source check.vim
+CheckFeature conceal
 
 if !has('gui_running') && has('unix')
   set term=ansi
index 519ac4b9a361d686004d409db090e08b40366a3f..b51a110e01d97fcb1431b8039b9afae5017d0cd6 100644 (file)
@@ -1,15 +1,15 @@
 " Tests for memory usage.
 
-if !has('terminal')
-  throw 'Skipped, terminal feature missing'
-endif
+source check.vim
+CheckFeature terminal
+
 if has('gui_running')
-  throw 'Skipped, does not work in GUI'
+  throw 'Skipped: does not work in GUI'
 endif
 if execute('version') =~# '-fsanitize=[a-z,]*\<address\>'
   " Skip tests on Travis CI ASAN build because it's difficult to estimate
   " memory usage.
-  throw 'Skipped, does not work with ASAN'
+  throw 'Skipped: does not work with ASAN'
 endif
 
 source shared.vim
@@ -20,7 +20,7 @@ endfunc
 
 if has('win32')
   if !executable('wmic')
-    throw 'Skipped, wmic program missing'
+    throw 'Skipped: wmic program missing'
   endif
   func s:memory_usage(pid) abort
     let cmd = printf('wmic process where processid=%d get WorkingSetSize', a:pid)
@@ -28,13 +28,13 @@ if has('win32')
   endfunc
 elseif has('unix')
   if !executable('ps')
-    throw 'Skipped, ps program missing'
+    throw 'Skipped: ps program missing'
   endif
   func s:memory_usage(pid) abort
     return s:pick_nr(system('ps -o rss= -p ' . a:pid))
   endfunc
 else
-  throw 'Skipped, not win32 or unix'
+  throw 'Skipped: not win32 or unix'
 endif
 
 " Wait for memory usage to level off.
index 99f888af19dd4086b2b31002af6fb22e80816cf6..efbb982b041f7590d025d33ccacd0d0178ec0998 100644 (file)
@@ -1,8 +1,7 @@
 " Test that the system menu can be loaded.
 
-if !has('menu')
-  throw 'Skipped, menu feature missing'
-endif
+source check.vim
+CheckFeature menu
 
 func Test_load_menu()
   try
index ee2d148c6731019969c2ef0233977392e4b76e6f..e7aa25ca7aa5c05212bc6832be8be78ae22a4bb7 100644 (file)
@@ -3,9 +3,8 @@
 set encoding=latin1
 scriptencoding latin1
 
-if !has('mksession')
-  throw 'Skipped, mksession feature missing'
-endif
+source check.vim
+CheckFeature mksession
 
 source shared.vim
 
index 6bf5823ce8257c45dc5c2ef306e9ee374510efe3..7d9a909cacf9fea1223acc5c9802d3dadacd6b66 100644 (file)
@@ -3,9 +3,8 @@
 set encoding=utf-8
 scriptencoding utf-8
 
-if !has('mksession')
-  throw 'Skipped, mksession feature missing'
-endif
+source check.vim
+CheckFeature mksession
 
 func Test_mksession_utf8()
   tabnew
index 836bddff3c18b3635da2df0a880f333bc143defd..690ac673c13ff19c86ae6e99580faf7f77e9bd71 100644 (file)
@@ -1,14 +1,13 @@
 " Test the netbeans interface.
 
-if !has('netbeans_intg')
-  throw 'Skipped, netbeans_intg feature missing'
-endif
+source check.vim
+CheckFeature netbeans_intg
 
 source shared.vim
 
 let s:python = PythonProg()
 if s:python == ''
-  throw 'Skipped, python program missing'
+  throw 'Skipped: python program missing'
 endif
 
 " Run "testfunc" after sarting the server and stop the server afterwards.
index ee69641538f6ea333cc4192042eff2bde848aa5b..a22e8e505ee3acc495b86cd150c79cded798005f 100644 (file)
@@ -2,10 +2,10 @@
 
 " Bracketed paste only works with "xterm".  Not in GUI or Windows console.
 if has('win32')
-  throw 'Skipped, does not work on MS-Windows'
+  throw 'Skipped: does not work on MS-Windows'
 endif
 if has('gui_running')
-  throw 'Skipped, does not work in the GUI'
+  throw 'Skipped: does not work in the GUI'
 endif
 set term=xterm
 
index d38fc079820ea238b04ba441e994eb584347b96d..8f23f2c136bdce823f79cdb39ca0af74e551e5eb 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for Perl interface
 
-if !has('perl')
-  throw 'Skipped, perl feature missing'
-end
+source check.vim
+CheckFeature perl
 
 " FIXME: RunTest don't see any error when Perl abort...
 perl $SIG{__WARN__} = sub { die "Unexpected warnings from perl: @_" };
index d9b0b295f742465816b2178009eda43f0ce93f11..a3f2046f4c3fbdc2fa321dde729592f1c90910d6 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for popup windows
 
-if !has('textprop')
-  throw 'Skipped: textprop feature missing'
-endif
+source check.vim
+CheckFeature textprop
 
 source screendump.vim
 
@@ -515,7 +514,7 @@ endfunc
 
 func Test_popup_time()
   if !has('timers')
-    throw 'Skipped, timer feature not supported'
+    throw 'Skipped: timer feature not supported'
   endif
   topleft vnew
   call setline(1, 'hello')
@@ -1176,7 +1175,7 @@ endfunc
 
 func Test_notifications()
   if !has('timers')
-    throw 'Skipped, timer feature not supported'
+    throw 'Skipped: timer feature not supported'
   endif
   if !CanRunVimInTerminal()
     throw 'Skipped: cannot make screendumps'
index ddabe3a953623e135e3233d1481ed9ec750d0a36..babed36dbdd232fb8613ec7ab985220b49b3408c 100644 (file)
@@ -1,8 +1,7 @@
 " Test Vim profiler
 
-if !has('profile')
-  throw 'Skipped, profile feature missing'
-endif
+source check.vim
+CheckFeature profile
 
 func Test_profile_func()
   let lines =<< trim [CODE]
index 5cf65d5135e5cf28b7c15627ceefa74a07740443..58be50bcbf58e11126c737ca1fd09de271d59009 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for setting 'buftype' to "prompt"
 
-if !has('channel')
-  throw 'Skipped, channel feature missing'
-endif
+source check.vim
+CheckFeature channel
 
 source shared.vim
 source screendump.vim
index 5b1085228831d436041529af5dd9f395733f3e69..61cf959bad2e9cb6becbae7ecfdcd26dbc02c2af 100644 (file)
@@ -1,9 +1,8 @@
 " Test for python 2 commands.
 " TODO: move tests from test87.in here.
 
-if !has('python')
-  throw 'Skipped, python feature missing'
-endif
+source check.vim
+CheckFeature python
 
 func Test_pydo()
   " Check deleting lines does not trigger ml_get error.
index e001360e75537c550752098fb55833fb73cfe249..7f486192093202b38755e348112fa7d465c47f66 100644 (file)
@@ -1,9 +1,8 @@
 " Test for python 3 commands.
 " TODO: move tests from test88.in here.
 
-if !has('python3')
-  throw 'Skipped, python3 feature missing'
-endif
+source check.vim
+CheckFeature python3
 
 func Test_py3do()
   " Check deleting lines does not trigger an ml_get error.
index 64bd579c268eaeec76c715a29c3f86cd8dbf5398..40e93c227b49531c6ac009ff84ac38e27b5d075c 100644 (file)
@@ -1,9 +1,8 @@
 " Test for pyx* commands and functions with Python 2.
 
 set pyx=2
-if !has('python')
-  throw 'Skipped, python feature missing'
-endif
+source check.vim
+CheckFeature python
 
 let s:py2pattern = '^2\.[0-7]\.\d\+'
 let s:py3pattern = '^3\.\d\+\.\d\+'
index 1b7bdae793c56940d7b88d3fa2ddfc19173070d2..5dfa6cd21ce4f13407403f44762b37b1e13a5712 100644 (file)
@@ -1,9 +1,8 @@
 " Test for pyx* commands and functions with Python 3.
 
 set pyx=3
-if !has('python3')
-  throw 'Skipped, python3 feature missing'
-endif
+source check.vim
+CheckFeature python3
 
 let s:py2pattern = '^2\.[0-7]\.\d\+'
 let s:py3pattern = '^3\.\d\+\.\d\+'
index 2fa28c9947f7b2a5e03af7e855f1071baef36d14..7d85f629be25429c9a09453768e8ca0fe305d55f 100644 (file)
@@ -1,8 +1,7 @@
 " Test for the quickfix feature.
 
-if !has('quickfix')
-  throw 'Skipped, quickfix feature missing'
-endif
+source check.vim
+CheckFeature quickfix
 
 set encoding=utf-8
 
index b6dab6b57138e9acc468690a2f4a6f466432c60d..d21ab35fcc19e035bb4df6c4341435a5a63f54be 100644 (file)
@@ -2,7 +2,7 @@
 
 source shared.vim
 if !WorkingClipboard()
-  throw 'Skipped, no working clipboard'
+  throw 'Skipped: no working clipboard'
 endif
 
 source shared.vim
index 18765391034ff58e915561eb008af72ef3829af5..404ea3f7aa3f0273605634dbb9fa6791a548384a 100644 (file)
@@ -1,11 +1,8 @@
 " Tests for reltime()
 
-if !has('reltime')
-  throw 'Skipped, reltime feature missing'
-endif
-if !has('float')
-  throw 'Skipped, float feature missing'
-endif
+source check.vim
+CheckFeature reltime
+CheckFeature float
 
 func Test_reltime()
   let now = reltime()
index dcfdc62448cae59128b97dd70684f88163d561ec..f679bbd5f4ae215e47ff7e964d5dd06c9e9bfb62 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for ruby interface
 
-if !has('ruby')
-  throw 'Skipped, ruby feature missing'
-end
+source check.vim
+CheckFeature ruby
 
 func Test_ruby_change_buffer()
   call setline(line('$'), ['1 line 1'])
index 7f802b143bbc828b6cac3935f05727dd5e930aa7..d0f92b1bad31685793ad587a1325df540c55fa16 100644 (file)
@@ -1,11 +1,8 @@
 " Tests for the sha256() function.
 
-if !has('cryptv')
-  throw 'Skipped, cryptv feature missing'
-endif
-if !exists('*sha256')
-  throw 'Skipped, sha256 function missing'
-endif
+source check.vim
+CheckFeature cryptv
+CheckFunction sha256
 
 function Test_sha256()
   " test for empty string:
index 564cd961236870aee1235c720539a709c9af4ca1..2d48f4b715604b9943890cccc3698c0c01a4b270 100644 (file)
@@ -2,7 +2,7 @@
 " Only for use on Win32 systems!
 
 if !has('win32')
-  throw 'Skipped, not on MS-Windows'
+  throw 'Skipped: not on MS-Windows'
 endif
 
 func TestIt(file, bits, expected)
index 365958a387e1bc1a044bde99535eb381759cef6a..44732df88d3f0e29e1ef096075617b88d588cafd 100644 (file)
@@ -1,7 +1,7 @@
 " Test signal handling.
 
 if !has('unix')
-  throw 'Skipped, not on Unix'
+  throw 'Skipped: not on Unix'
 endif
 
 source shared.vim
index 4a23e4ba1bbc9a2dfa3c931a374eaf71fa736dc7..3b17eccf07825fe6f18272defc9937abb49fb6ed 100644 (file)
@@ -1,8 +1,7 @@
 " Test for signs
 
-if !has('signs')
-  throw 'Skipped, signs feature missing'
-endif
+source check.vim
+CheckFeature signs
 
 func Test_sign()
   new
index 72599fdc138950bf8f7375b99a2a562915de52dc..48bc3b3e2eac67182b48b1d55509a560d3e911b2 100644 (file)
@@ -1,8 +1,7 @@
 " Test spell checking
 
-if !has('spell')
-  throw 'Skipped, spell feature missing'
-endif
+source check.vim
+CheckFeature spell
 
 func TearDown()
   set nospell
index 8d9d7d35c17cd00559c3035304ba32605cd08be3..c9808bec4f6ed665901433e95a1b5decdc41455b 100644 (file)
@@ -1,8 +1,7 @@
 " Test for syntax and syntax iskeyword option
 
-if !has("syntax")
-  throw 'Skipped, syntax feature missing'
-endif
+source check.vim
+CheckFeature syntax
 
 source view_util.vim
 source screendump.vim
index 8ccd34c6b6238fd893912b117b6f12872cfdcb5c..9923a2e332a6c188152811bbb3f9e7c530c7314a 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for the Tcl interface.
 
-if !has('tcl')
-  throw 'Skipped, tcl feature missing'
-end
+source check.vim
+CheckFeature tcl
 
 " Helper function as there is no builtin tcleval() function similar
 " to perleval, luaevel(), pyeval(), etc.
index 9d7f6b5fa788582897132606a24ee891d44fdff9..c6327db6ac681ea515d147a0a6837aa11f342618 100644 (file)
@@ -2,10 +2,10 @@
 
 " This only works for Unix in a terminal
 if has('gui_running')
-  throw 'Skipped, does not work in the GUI'
+  throw 'Skipped: does not work in the GUI'
 endif
 if !has('unix')
-  throw 'Skipped, not on Unix'
+  throw 'Skipped: not on Unix'
 endif
 
 source shared.vim
index 09c050aada259d1b6f0253de249158f339b56e48..f1cd7da33d5cd29f1af9e087b1bd249d84fc922b 100644 (file)
@@ -1,8 +1,7 @@
 " Tests for the terminal window.
 
-if !has('terminal')
-  throw 'Skipped, terminal feature missing'
-endif
+source check.vim
+CheckFeature terminal
 
 source shared.vim
 source screendump.vim
index d010c3b8f147cf7dc14b1ebb86b2978efe6519a5..f33ade63428cddc7ef49913f15c5daa243587b15 100644 (file)
@@ -2,9 +2,8 @@
 " leaks under valgrind.  That is because when fork/exec fails memory is not
 " freed.  Since the process exists right away it's not a real leak.
 
-if !has('terminal')
-  throw 'Skipped, terminal feature missing'
-endif
+source check.vim
+CheckFeature terminal
 
 source shared.vim
 
index 5366a35fbae1b488006e5a5c1b76e725f04007bd..a3e3851f422dc4280f9f3c17ad5e38a4e52015c3 100644 (file)
@@ -1,8 +1,7 @@
 " Test for textobjects
 
-if !has('textobjects')
-  throw 'Skipped, textobjects feature missing'
-endif
+source check.vim
+CheckFeature textobjects
 
 func CpoM(line, useM, expected)
   new
index cb27f5877c98dcac974c0d82ec2a70e07535f155..08c079cfa4eac90b7c677ed52bc55d63c80ad925 100644 (file)
@@ -1,9 +1,8 @@
 " Tests for defining text property types and adding text properties to the
 " buffer.
 
-if !has('textprop')
-  throw 'Skipped, textprop feature missing'
-endif
+source check.vim
+CheckFeature textprop
 
 source screendump.vim
 
index 5b09011c7555b4ea2702aeb4cbc236bca1776ee0..03391d8f52e64dec594db8e2ca2f2843a8da81fa 100644 (file)
@@ -1,8 +1,7 @@
 " Test for timers
 
-if !has('timers')
-  throw 'Skipped, timers feature missing'
-endif
+source check.vim
+CheckFeature timers
 
 source shared.vim
 source screendump.vim
index 640aa0b305d3223084858b08438619d9dd59e634..b0f3e15aab18a92a2d03d2ae7a7769d853521605 100644 (file)
@@ -1,8 +1,7 @@
 " Test for variable tabstops
 
-if !has("vartabs")
-  throw 'Skipped, vartabs feature missing'
-endif
+source check.vim
+CheckFeature vartabs
 
 source view_util.vim
 
index 51ef0a8633b04293d51c4dbddcf3ebe0c8941bbb..5e4366717aaa99b66fef1d57e4ea9611609db709 100644 (file)
@@ -1,8 +1,7 @@
 " Test WinBar
 
-if !has('menu')
-  throw 'Skipped, menu feature missing'
-endif
+source check.vim
+CheckFeature menu
 
 source shared.vim
 
index da95ed27c8bef966e7a82091984de248ad97fe9e..8ac9ce0fdeb17dcbb51ea7e9d5660c8ea35c0900 100644 (file)
@@ -1,7 +1,7 @@
 " Test for $HOME on Windows.
 
 if !has('win32')
-  throw 'Skipped, not on MS-Windows'
+  throw 'Skipped: not on MS-Windows'
 endif
 
 let s:env = {}
index 63ac574abba791782181a3a9ce8b126800a72726..cf47c8a9c0e2e1d8b9dd74d8175bb66e95023337 100644 (file)
@@ -2,7 +2,7 @@
 if empty($XXD) && executable('..\xxd\xxd.exe')
   let s:xxd_cmd = '..\xxd\xxd.exe'
 elseif empty($XXD) || !executable($XXD)
-  throw 'Skipped, xxd program missing'
+  throw 'Skipped: xxd program missing'
 else
   let s:xxd_cmd = $XXD
 endif
index 0b036d031b7dd324b24ddae47d59017db759d4db..e4ef380d881d48cd8b96e196a07c885dc4ac2e0f 100644 (file)
@@ -777,6 +777,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1544,
 /**/
     1543,
 /**/