mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
Merge pull request #14155 from janlazo/vim-8.2.2609
vim-patch:8.2.{2609,2611}
This commit is contained in:
commit
0f7b6b2efd
2
.gitignore
vendored
2
.gitignore
vendored
@ -35,7 +35,7 @@ compile_commands.json
|
||||
/src/nvim/testdir/del
|
||||
/src/nvim/testdir/test*.out
|
||||
/src/nvim/testdir/test*.res
|
||||
/src/nvim/testdir/test.log
|
||||
/src/nvim/testdir/test*.log
|
||||
/src/nvim/testdir/messages
|
||||
/src/nvim/testdir/viminfo
|
||||
/src/nvim/testdir/test.ok
|
||||
|
@ -108,3 +108,30 @@ func CheckNotMSWindows()
|
||||
throw 'Skipped: does not work on MS-Windows'
|
||||
endif
|
||||
endfunc
|
||||
|
||||
" Command to check for satisfying any of the conditions.
|
||||
" e.g. CheckAnyOf Feature:bsd Feature:sun Linux
|
||||
command -nargs=+ CheckAnyOf call CheckAnyOf(<f-args>)
|
||||
func CheckAnyOf(...)
|
||||
let excp = []
|
||||
for arg in a:000
|
||||
try
|
||||
exe 'Check' .. substitute(arg, ':', ' ', '')
|
||||
return
|
||||
catch /^Skipped:/
|
||||
let excp += [substitute(v:exception, '^Skipped:\s*', '', '')]
|
||||
endtry
|
||||
endfor
|
||||
throw 'Skipped: ' .. join(excp, '; ')
|
||||
endfunc
|
||||
|
||||
" Command to check for satisfying all of the conditions.
|
||||
" e.g. CheckAllOf Unix Gui Option:ballooneval
|
||||
command -nargs=+ CheckAllOf call CheckAllOf(<f-args>)
|
||||
func CheckAllOf(...)
|
||||
for arg in a:000
|
||||
exe 'Check' .. substitute(arg, ':', ' ', '')
|
||||
endfor
|
||||
endfunc
|
||||
|
||||
" vim: shiftwidth=2 sts=2 expandtab
|
||||
|
@ -111,7 +111,8 @@ func Test_pack_in_rtp_when_plugins_run()
|
||||
endfunc
|
||||
|
||||
func Test_help_arg()
|
||||
CheckNotMSWindows
|
||||
" This does not work with a GUI-only binary, such as on MS-Windows.
|
||||
CheckAnyOf Unix NotGui
|
||||
|
||||
if RunVim([], [], '--help >Xtestout')
|
||||
let lines = readfile('Xtestout')
|
||||
@ -427,7 +428,7 @@ endfunction
|
||||
" Test the -reverse and +reverse arguments (for GUI only).
|
||||
func Test_reverse()
|
||||
CheckCanRunGui
|
||||
CheckNotMSWindows
|
||||
CheckAnyOf Feature:gui_gtk Feature:gui_motif Feature:gui_athena
|
||||
|
||||
let after =<< trim [CODE]
|
||||
call writefile([&background], "Xtest_reverse")
|
||||
@ -448,7 +449,7 @@ endfunc
|
||||
" Test the -background and -foreground arguments (for GUI only).
|
||||
func Test_background_foreground()
|
||||
CheckCanRunGui
|
||||
CheckNotMSWindows
|
||||
CheckAnyOf Feature:gui_gtk Feature:gui_motif Feature:gui_athena
|
||||
|
||||
" Is there a better way to check the effect of -background & -foreground
|
||||
" other than merely looking at &background (dark or light)?
|
||||
@ -497,7 +498,7 @@ endfunc
|
||||
" Test the -geometry argument (for GUI only).
|
||||
func Test_geometry()
|
||||
CheckCanRunGui
|
||||
CheckNotMSWindows
|
||||
CheckAnyOf Feature:gui_gtk Feature:gui_motif Feature:gui_athena
|
||||
|
||||
if has('gui_motif') || has('gui_athena')
|
||||
" FIXME: With GUI Athena or Motif, the value of getwinposx(),
|
||||
@ -529,7 +530,7 @@ endfunc
|
||||
" Test the -iconic argument (for GUI only).
|
||||
func Test_iconic()
|
||||
CheckCanRunGui
|
||||
CheckNotMSWindows
|
||||
CheckAnyOf Feature:gui_gtk Feature:gui_motif Feature:gui_athena
|
||||
|
||||
call RunVim([], [], '-f -g -iconic -cq')
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user