mirror of
https://github.com/neovim/neovim.git
synced 2025-10-16 23:06:14 +00:00
fix: ensure has() does not change v:shell_error (#18415)
(cherry picked from commit 0f21816b5f
)
Co-authored-by: Andrey Mishchenko <mishchea@gmail.com>
This commit is contained in:
![41898282+github-actions[bot]@users.noreply.github.com](/assets/img/avatar_default.png)
committed by
GitHub

parent
203b088d75
commit
1e28068d0d
@@ -68,4 +68,11 @@ describe('has()', function()
|
||||
eq(0, funcs.has('wsl'))
|
||||
end
|
||||
end)
|
||||
|
||||
it('does not change v:shell_error', function()
|
||||
local nvim_prog = helpers.nvim_prog
|
||||
funcs.system({nvim_prog, '-es', '+73cquit'})
|
||||
funcs.has('python3') -- use a call whose implementation shells out
|
||||
eq(73, funcs.eval('v:shell_error'))
|
||||
end)
|
||||
end)
|
||||
|
Reference in New Issue
Block a user