mirror of
https://github.com/neovim/neovim.git
synced 2025-09-05 19:08:15 +00:00
test(lua/hl_spec): reduce flakiness (#32489)
This commit is contained in:
@@ -27,6 +27,14 @@ describe('vim.hl.range', function()
|
||||
'口口=口口',
|
||||
'zxcvbnm',
|
||||
})
|
||||
screen:expect([[
|
||||
^asdfghjkl{1:$} |
|
||||
«口=口»{1:$} |
|
||||
qwertyuiop{1:$} |
|
||||
口口=口口{1:$} |
|
||||
zxcvbnm{1:$} |
|
||||
|
|
||||
]])
|
||||
end)
|
||||
|
||||
it('works with charwise selection', function()
|
||||
@@ -106,7 +114,7 @@ describe('vim.hl.range', function()
|
||||
end)
|
||||
|
||||
it('removes highlight after given `timeout`', function()
|
||||
local timeout = 100
|
||||
local timeout = 300
|
||||
exec_lua(function()
|
||||
local ns = vim.api.nvim_create_namespace('')
|
||||
vim.hl.range(0, ns, 'Search', { 0, 0 }, { 4, 0 }, { timeout = timeout })
|
||||
@@ -120,7 +128,7 @@ describe('vim.hl.range', function()
|
||||
zxcvbnm{1:$} |
|
||||
|
|
||||
]],
|
||||
timeout = timeout,
|
||||
timeout = timeout / 3,
|
||||
})
|
||||
screen:expect([[
|
||||
^asdfghjkl{1:$} |
|
||||
|
Reference in New Issue
Block a user