mirror of
https://github.com/junegunn/vim-plug.git
synced 2025-12-07 01:24:27 +08:00
Use build stages to group related jobs (Vim, Neovim, Vim 7.4). Use "silent" to avoid hit-enter prompt when redirecting output. Always run async and sync tests to debug runtime errors. Vim 7.4.0052 (Ubuntu Trusty) does not allow dynamic keys in inline dictionary. https://docs.travis-ci.com/user/build-stages/
This commit is contained in:
@@ -50,7 +50,7 @@ Execute (Test Plug command):
|
||||
|
||||
^ Git repo with tag (DEPRECATED. USE TAG OPTION)
|
||||
redir => out
|
||||
Plug 'foo/bar.vim', ''
|
||||
silent Plug 'foo/bar.vim', ''
|
||||
redir END
|
||||
Assert out =~ 'Invalid argument for "tag" option of :Plug (expected: string)'
|
||||
Plug 'junegunn/goyo.vim', '1.5.2'
|
||||
@@ -59,7 +59,7 @@ Execute (Test Plug command):
|
||||
AssertEqual '1.5.2', g:plugs['goyo.vim'].tag
|
||||
|
||||
redir => out
|
||||
Plug 'foo/bar.vim', {'tag': ''}
|
||||
silent Plug 'foo/bar.vim', {'tag': ''}
|
||||
redir END
|
||||
Assert out =~ 'Invalid argument for "tag" option of :Plug (expected: string)'
|
||||
Plug 'junegunn/goyo.vim', { 'tag': '1.5.3' } " Using tag option
|
||||
@@ -86,19 +86,23 @@ Execute (Test Plug command):
|
||||
Execute (Plug command with dictionary option):
|
||||
Log string(g:plugs)
|
||||
for opt in ['branch', 'tag', 'commit', 'rtp', 'dir', 'as']
|
||||
let opts = {}
|
||||
let opts[opt] = ''
|
||||
redir => out
|
||||
Plug 'foo/bar.vim', {opt: ''}
|
||||
silent Plug 'foo/bar.vim', opts
|
||||
redir END
|
||||
Assert out =~ 'Invalid argument for "'.opt.'" option of :Plug (expected: string)'
|
||||
endfor
|
||||
for opt in ['on', 'for']
|
||||
let opts = {}
|
||||
let opts[opt] = ''
|
||||
redir => out
|
||||
Plug 'foo/bar.vim', {opt: ''}
|
||||
silent Plug 'foo/bar.vim', opts
|
||||
redir END
|
||||
Assert out =~ 'Invalid argument for "'.opt.'" option of :Plug (expected: string or list)'
|
||||
endfor
|
||||
redir => out
|
||||
Plug 'foo/bar.vim', {'do': ''}
|
||||
silent Plug 'foo/bar.vim', {'do': ''}
|
||||
redir END
|
||||
Assert out =~ 'Invalid argument for "do" option of :Plug (expected: string or funcref)'
|
||||
Plug 'junegunn/seoul256.vim', { 'branch': 'no-t_co', 'rtp': '././' }
|
||||
|
||||
Reference in New Issue
Block a user