mirror of
https://github.com/neovim/neovim.git
synced 2026-02-28 14:25:07 +00:00
test(ui): failure in lua/ui_spec.lua in headless OS (no GUI) #37975
This commit is contained in:
@@ -143,9 +143,14 @@ describe('vim.ui', function()
|
||||
exec_lua [[vim.system = function() return { wait=function() return { code=3 } end } end]]
|
||||
end
|
||||
if not is_os('bsd') then
|
||||
local rv =
|
||||
exec_lua [[local cmd = vim.ui.open('non-existent-file'); return cmd:wait(100).code]]
|
||||
ok(type(rv) == 'number' and rv ~= 0, 'nonzero exit code', rv)
|
||||
local rv = exec_lua([[
|
||||
local cmd, err = vim.ui.open('non-existent-file')
|
||||
if err then return nil end
|
||||
return cmd:wait(100).code
|
||||
]])
|
||||
if type(rv) == 'number' then
|
||||
ok(rv ~= 0, 'nonzero exit code', rv)
|
||||
end
|
||||
end
|
||||
|
||||
exec_lua [[
|
||||
|
||||
Reference in New Issue
Block a user