]> granicus.if.org Git - vim/commitdiff
patch 8.2.2831: Vim9: expandcmd() not tested v8.2.2831
authorBram Moolenaar <Bram@vim.org>
Mon, 3 May 2021 19:40:26 +0000 (21:40 +0200)
committerBram Moolenaar <Bram@vim.org>
Mon, 3 May 2021 19:40:26 +0000 (21:40 +0200)
Problem:    Vim9: expandcmd() not tested.
Solution:   Add a test.

src/testdir/test_vim9_builtin.vim
src/version.c

index bd84a6ca1a7dd0a3465a72cab301f43eeb3facba..46fe3e5ca8d0c98718c7e8eb5c8ec6741920f6db 100644 (file)
@@ -336,6 +336,13 @@ def Test_expand()
   close
 enddef
 
+def Test_expandcmd()
+  $FOO = "blue"
+  assert_equal("blue sky", expandcmd("`=$FOO .. ' sky'`"))
+
+  assert_equal("yes", expandcmd("`={a: 'yes'}['a']`"))
+enddef
+
 def Test_extend_arg_types()
   g:number_one = 1
   g:string_keep = 'keep'
index 63ede845ca3892a19a25289dc063a0d947a88bce..d9868ef902f10b15f9b30ea09a5c3b01707fbebf 100644 (file)
@@ -750,6 +750,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    2831,
 /**/
     2830,
 /**/