" Unlike X11, we need the socket server running if we want to send commands to
" a server via sockets.
-if v:servername == ""
- call remote_startserver('VIMSOCKETSERVERTEST')
-endif
+CheckSocketServer
func Check_X11_Connection()
if has('x11')
import './util/vim9.vim' as v9
" Socket backend for remote functions require the socket server to be running
-if v:servername == ""
- call remote_startserver('VIMSOCKETSERVERTEST')
-endif
+CheckSocketServer
" Test for passing too many or too few arguments to builtin functions
func Test_internalfunc_arg_error()
CheckFeature x11
try
call remote_send('xxx', '')
+ catch /^Vim\%((\a\+)\)\=:E240:/ " not possible to start a remote server
+ throw 'Skipped: No connection to the X server possible'
catch
- if v:exception =~ 'E240:'
- thrclientserverow 'Skipped: no connection to the X server'
- endif
" ignore other errors
endtry
endfunc
endif
endfunc
+command CheckSocketServer call CheckSocketServer()
+func CheckSocketServer()
+ if v:servername == ""
+ try
+ call remote_startserver('VIMSOCKETSERVERTEST')
+ catch /^Vim\%((\a\+)\)\=:E240:/ " not possible to start a remote server
+ throw 'Skipped: Cannot start remote server'
+ endtry
+ endif
+endfunc
+
let &cpo = s:cpo_save
unlet s:cpo_save
" vim: shiftwidth=2 sts=2 expandtab
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1733,
/**/
1732,
/**/