[neovim] 04/08: tui_spec: Convert nil to "" before formatting it
James McCoy
jamessan at debian.org
Mon Nov 13 02:55:41 UTC 2017
This is an automated email from the git hooks/post-receive script.
jamessan pushed a commit to branch debian/sid
in repository neovim.
commit 1e96b546aa2b46dcd33fdff67cacab04a588aa00
Author: James McCoy <jamessan at jamessan.com>
Date: Thu Nov 9 23:19:25 2017 -0500
tui_spec: Convert nil to "" before formatting it
This fixes an apparent difference in behavior between Lua and LuaJIT.
Lua fails to format nil:
test/functional/terminal/tui_spec.lua:381: bad argument #2 to 'format' (string expected, got nil)
---
test/functional/terminal/tui_spec.lua | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/test/functional/terminal/tui_spec.lua b/test/functional/terminal/tui_spec.lua
index d36eb46..777ef65 100644
--- a/test/functional/terminal/tui_spec.lua
+++ b/test/functional/terminal/tui_spec.lua
@@ -380,7 +380,7 @@ describe("tui 't_Co' (terminal colors)", function()
-- TODO: Revisit this after jobstart/termopen accept `env` dict.
screen = thelpers.screen_setup(0, string.format(
[=[['sh', '-c', 'LANG=C TERM=%s %s %s -u NONE -i NONE --cmd "silent set noswapfile noshowcmd noruler"']]=],
- term,
+ term or "",
(colorterm ~= nil and "COLORTERM="..colorterm or ""),
helpers.nvim_prog))
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-vim/neovim.git
More information about the pkg-vim-maintainers
mailing list