aboutsummaryrefslogtreecommitdiff
path: root/test/functional/helpers.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2017-01-14 09:47:33 +0100
committerJustin M. Keyes <justinkz@gmail.com>2017-01-19 09:55:57 +0100
commite40946a5be2ce11156fc7494ec81040d3cde4809 (patch)
tree02b2c35a2d9f7f83db8acc3650d006544d1f4e16 /test/functional/helpers.lua
parent75e6af44e03e706df896df8b57d8e29c9a0d0f41 (diff)
downloadrneovim-e40946a5be2ce11156fc7494ec81040d3cde4809.tar.gz
rneovim-e40946a5be2ce11156fc7494ec81040d3cde4809.tar.bz2
rneovim-e40946a5be2ce11156fc7494ec81040d3cde4809.zip
win: test: enable job_spec.lua
- Default to powershell. - Avoid hardcoded "-c". - Remove ^M character from received lines. - pending_win32(): clear() is unnecessary and it pollutes the tests. Closes #3973 Helped-by: Rui Abreu Ferreira <raf-ep@gmx.com>
Diffstat (limited to 'test/functional/helpers.lua')
-rw-r--r--test/functional/helpers.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/functional/helpers.lua b/test/functional/helpers.lua
index 2939184d2c..d9c85c03f8 100644
--- a/test/functional/helpers.lua
+++ b/test/functional/helpers.lua
@@ -169,6 +169,10 @@ local os_name = (function()
end)
end)()
+local function iswin()
+ return os_name() == 'windows'
+end
+
-- Executes a VimL function.
-- Fails on VimL error, but does not update v:errmsg.
local function nvim_call(name, ...)
@@ -502,7 +506,6 @@ end
-- Helper to skip tests. Returns true in Windows systems.
-- pending_fn is pending() from busted
local function pending_win32(pending_fn)
- clear()
if uname() == 'Windows' then
if pending_fn ~= nil then
pending_fn('FIXME: Windows', function() end)
@@ -553,6 +556,7 @@ return function(after_each)
source = source,
rawfeed = rawfeed,
insert = insert,
+ iswin = iswin,
feed = feed,
execute = execute,
eval = nvim_eval,