]> granicus.if.org Git - vim/commitdiff
patch 8.2.0701: Vim9 test fails without job feature v8.2.0701
authorBram Moolenaar <Bram@vim.org>
Tue, 5 May 2020 21:32:58 +0000 (23:32 +0200)
committerBram Moolenaar <Bram@vim.org>
Tue, 5 May 2020 21:32:58 +0000 (23:32 +0200)
Problem:    Vim9 test fails without job feature.
Solution:   Add feature check.

src/testdir/test_vim9_script.vim
src/version.c

index 76ce2e5498816a3b2132db46bb56a699e28a1459..40aae46a145729e38c49593738d7d615a68e4caa 100644 (file)
@@ -466,19 +466,21 @@ def Test_try_catch_fails()
   call CheckDefFailure(['throw xxx'], 'E1001:')
 enddef
 
-let someJob = test_null_job()
+if has('channel')
+  let someJob = test_null_job()
 
-def FuncWithError()
-  echomsg g:someJob
-enddef
+  def FuncWithError()
+    echomsg g:someJob
+  enddef
 
-func Test_convert_emsg_to_exception()
-  try
-    call FuncWithError()
-  catch
-    call assert_match('Vim:E908:', v:exception)
-  endtry
-endfunc
+  func Test_convert_emsg_to_exception()
+    try
+      call FuncWithError()
+    catch
+      call assert_match('Vim:E908:', v:exception)
+    endtry
+  endfunc
+endif
 
 let s:export_script_lines =<< trim END
   vim9script
index 4c743cbfa18678e149fff90b24a3aeb58d81dfef..0dc91da61a33ef757906c289daf67003d1558fdc 100644 (file)
@@ -746,6 +746,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    701,
 /**/
     700,
 /**/