]> granicus.if.org Git - vim/commitdiff
patch 7.4.1993 v7.4.1993
authorBram Moolenaar <Bram@vim.org>
Thu, 7 Jul 2016 13:11:19 +0000 (15:11 +0200)
committerBram Moolenaar <Bram@vim.org>
Thu, 7 Jul 2016 13:11:19 +0000 (15:11 +0200)
Problem:    Not all TRUE and FALSE arguments are tested.
Solution:   Add a few more tests.

src/testdir/test_true_false.vim
src/version.c

index 90b4f5e37a5c8f6beea11eca9cbe4f434e3a0943..f11d298ee6469f170e26525ae6817c0415eabb48 100644 (file)
@@ -85,6 +85,25 @@ func Test_true_false_arg()
     call Try_arg_true_false('globpath(".", "Xlink", 0, 0, %v%)', "", "./Xlink")
     silent !rm Xlink
   endif
+
+  abbr asdf asdff
+  call Try_arg_true_false('hasmapto("asdff", "i", %v%)', 0, 1)
+
+  call Try_arg_true_false('index(["a", "A"], "A", 0, %v%)', 1, 0)
+
+  call Try_arg_true_false('maparg("asdf", "i", %v%)', "", "asdff")
+  call Try_arg_true_false('maparg("asdf", "i", 1, %v%)', "asdff", {'silent': 0, 'noremap': 0, 'lhs': 'asdf', 'mode': '!', 'nowait': 0, 'expr': 0, 'sid': 3, 'rhs': 'asdff', 'buffer': 0})
+
+  call Try_arg_true_false('hasmapto("asdf", "i", %v%)', 0, 1)
+
+  new colored
+  call setline(1, '<here>')
+  syn match brackets "<.*>"
+  syn match here "here" transparent
+  let brackets_id = synID(1, 1, 0)
+  let here_id = synID(1, 3, 0)
+  call Try_arg_true_false('synID(1, 3, %v%)', here_id, brackets_id)
+  bwipe!
 endfunc
 
 function Try_arg_non_zero(expr, false_val, true_val)
index f235d762b4b86990dcee24998ed32de6cc4f2ba8..996745596bfcdeb9825a4c43c9d8cf2f6459611b 100644 (file)
@@ -758,6 +758,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1993,
 /**/
     1992,
 /**/