mirror of
https://github.com/neovim/neovim.git
synced 2025-09-22 19:18:34 +00:00
vim-patch:9.0.0537: the do_set() function is much too long (#20274)
Problem: The do_set() function is much too long.
Solution: Move setting of a string option to a separate function.
4740394f23
Cherry-pick some tests from Vim patch 8.2.0540.
This commit is contained in:
@@ -238,6 +238,15 @@ describe('ShaDa support code', function()
|
||||
eq('', meths.get_option('shada'))
|
||||
end)
|
||||
|
||||
it('setting &shada gives proper error message on missing number', function()
|
||||
eq([[Vim(set):E526: Missing number after <">: shada="]],
|
||||
exc_exec([[set shada=\"]]))
|
||||
for _, c in ipairs({"'", "/", ":", "<", "@", "s"}) do
|
||||
eq(([[Vim(set):E526: Missing number after <%s>: shada=%s]]):format(c, c),
|
||||
exc_exec(([[set shada=%s]]):format(c)))
|
||||
end
|
||||
end)
|
||||
|
||||
it('does not crash when ShaDa file directory is not writable', function()
|
||||
if helpers.pending_win32(pending) then return end
|
||||
|
||||
|
Reference in New Issue
Block a user