Merge pull request #17527 from zeertzjq/test-pending-win32

test: use helpers.pending_win32(pending) instead of iswin()
This commit is contained in:
zeertzjq 2022-02-26 21:17:38 +08:00 committed by GitHub
commit 41f309adeb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 10 deletions

View File

@ -824,6 +824,7 @@ describe('API: buffer events:', function()
end
msg = next_msg()
end
-- FIXME: Windows
assert(iswin(), 'did not match/receive expected nvim_buf_lines_event lines')
end

View File

@ -10,12 +10,11 @@ local funcs = helpers.funcs
local matches = helpers.matches
local pesc = helpers.pesc
local rmdir = helpers.rmdir
local iswin = helpers.iswin
local file_prefix = 'Xtest-functional-ex_cmds-mksession_spec'
describe(':mksession', function()
if not iswin() then
if helpers.pending_win32(pending) then return end
local session_file = file_prefix .. '.vim'
local tab_dir = file_prefix .. '.d'
@ -117,5 +116,4 @@ describe(':mksession', function()
matches('^term://'..pesc(expected_cwd)..'//%d+:', funcs.expand('%'))
command('qall!')
end)
end
end)

View File

@ -8,7 +8,6 @@ local eq, eval = helpers.eq, helpers.eval
local feed_command = helpers.feed_command
local hide_cursor = thelpers.hide_cursor
local show_cursor = thelpers.show_cursor
local iswin = helpers.iswin
describe(':terminal cursor', function()
local screen
@ -178,7 +177,7 @@ describe('cursor with customized highlighting', function()
end)
describe('buffer cursor position is correct in terminal without number column', function()
if not iswin() then
if helpers.pending_win32(pending) then return end
local screen
local function setup_ex_register(str)
@ -526,11 +525,10 @@ describe('buffer cursor position is correct in terminal without number column',
eq({6, 1}, eval('nvim_win_get_cursor(0)'))
end)
end)
end
end)
describe('buffer cursor position is correct in terminal with number column', function()
if not iswin() then
if helpers.pending_win32(pending) then return end
local screen
local function setup_ex_register(str)
@ -881,5 +879,4 @@ describe('buffer cursor position is correct in terminal with number column', fun
eq({6, 1}, eval('nvim_win_get_cursor(0)'))
end)
end)
end
end)

View File

@ -14,7 +14,7 @@ local has_powershell = helpers.has_powershell
local set_shell_powershell = helpers.set_shell_powershell
describe("shell command :!", function()
if not iswin() then
if helpers.pending_win32(pending) then return end
local screen
before_each(function()
clear()
@ -78,7 +78,6 @@ describe("shell command :!", function()
[10] = {foreground = 2},
})
end)
end
end)
describe("shell command :!", function()