diff options
author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2019-06-13 00:29:10 -0400 |
---|---|---|
committer | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2019-06-13 19:39:55 -0400 |
commit | 47a545667006ded57dc9660333e4ea2cab23b679 (patch) | |
tree | 27e837fd5e54f76aac3ec296e9bd219aa5a64472 /src | |
parent | e6a1bea1eb2f70f3a989295a2eaa18b3f49ddc02 (diff) | |
download | rneovim-47a545667006ded57dc9660333e4ea2cab23b679.tar.gz rneovim-47a545667006ded57dc9660333e4ea2cab23b679.tar.bz2 rneovim-47a545667006ded57dc9660333e4ea2cab23b679.zip |
vim-patch:8.0.0933: terminal test tries to start GUI when it's not possible
Problem: Terminal test tries to start GUI when it's not possible.
Solution: Check if the GUI can run. (James McCoy, closes vim/vim#1971)
https://github.com/vim/vim/commit/9f0139a2a869b0804e5b91a65e3d5952c9091879
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/testdir/shared.vim | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/nvim/testdir/shared.vim b/src/nvim/testdir/shared.vim index eb6798f353..29af05fe3f 100644 --- a/src/nvim/testdir/shared.vim +++ b/src/nvim/testdir/shared.vim @@ -246,3 +246,7 @@ func! Screenline(lnum) let line = join(chars, '') return matchstr(line, '^.\{-}\ze\s*$') endfunc + +func CanRunGui() + return has('gui') && ($DISPLAY != "" || has('gui_running')) +endfunc |