mirror of
https://github.com/neovim/neovim.git
synced 2025-11-23 10:36:29 +00:00
vim-patch:7.4.1768
Problem: Arguments of setqflist() are not checked properly.
Solution: Add better checks, add a test. (Nikolai Pavlov, Hirohito Higashi,
closes vim/vim#661)
d106e5ba7f
This commit is contained in:
@@ -18,9 +18,9 @@ describe('setqflist()', function()
|
||||
end)
|
||||
|
||||
it('requires a string for {action}', function()
|
||||
eq('Vim(call):E114: String required', exc_exec('call setqflist([], 5)'))
|
||||
eq('Vim(call):E114: String required', exc_exec('call setqflist([], [])'))
|
||||
eq('Vim(call):E114: String required', exc_exec('call setqflist([], {})'))
|
||||
eq('Vim(call):E928: String required', exc_exec('call setqflist([], 5)'))
|
||||
eq('Vim(call):E928: String required', exc_exec('call setqflist([], [])'))
|
||||
eq('Vim(call):E928: String required', exc_exec('call setqflist([], {})'))
|
||||
end)
|
||||
|
||||
it('sets w:quickfix_title', function()
|
||||
@@ -56,9 +56,9 @@ describe('setloclist()', function()
|
||||
end)
|
||||
|
||||
it('requires a string for {action}', function()
|
||||
eq('Vim(call):E114: String required', exc_exec('call setloclist(0, [], 5)'))
|
||||
eq('Vim(call):E114: String required', exc_exec('call setloclist(0, [], [])'))
|
||||
eq('Vim(call):E114: String required', exc_exec('call setloclist(0, [], {})'))
|
||||
eq('Vim(call):E928: String required', exc_exec('call setloclist(0, [], 5)'))
|
||||
eq('Vim(call):E928: String required', exc_exec('call setloclist(0, [], [])'))
|
||||
eq('Vim(call):E928: String required', exc_exec('call setloclist(0, [], {})'))
|
||||
end)
|
||||
|
||||
it('sets w:quickfix_title for the correct window', function()
|
||||
|
||||
Reference in New Issue
Block a user