aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2025-04-04 09:19:13 +0800
committerGitHub <noreply@github.com>2025-04-04 01:19:13 +0000
commit4ef9dcb1eb7d969687872699d92e0860f3c9ff3a (patch)
treedebbefcf5228774bcdb282d996aecca19d749f5b
parent71e133e5e66a3346ac57bb3287f0ca95dde8ffec (diff)
downloadrneovim-4ef9dcb1eb7d969687872699d92e0860f3c9ff3a.tar.gz
rneovim-4ef9dcb1eb7d969687872699d92e0860f3c9ff3a.tar.bz2
rneovim-4ef9dcb1eb7d969687872699d92e0860f3c9ff3a.zip
test(lua/hl_spec): fix hang on exit with ASAN (#33298)
-rw-r--r--test/functional/lua/hl_spec.lua12
1 files changed, 8 insertions, 4 deletions
diff --git a/test/functional/lua/hl_spec.lua b/test/functional/lua/hl_spec.lua
index e3c6c706c7..f17442912a 100644
--- a/test/functional/lua/hl_spec.lua
+++ b/test/functional/lua/hl_spec.lua
@@ -258,9 +258,9 @@ describe('vim.hl.on_yank', function()
eq({ win }, api.nvim__ns_get(ns).wins)
command('wincmd w')
eq({ win }, api.nvim__ns_get(ns).wins)
- -- Use a new vim.hl.range() call to cancel the previous timer
+ -- Use a new vim.hl.on_yank() call to cancel the previous timer
exec_lua(function()
- vim.hl.range(0, ns, 'Search', { 0, 0 }, { 0, 0 }, { timeout = 0 })
+ vim.hl.on_yank({ timeout = 0, on_macro = true, event = { operator = 'y' } })
end)
end)
@@ -283,9 +283,9 @@ describe('vim.hl.on_yank', function()
eq({ win }, api.nvim__ns_get(ns).wins)
command('wincmd w')
eq({ win }, api.nvim__ns_get(ns).wins)
- -- Use a new vim.hl.range() call to cancel the previous timer
+ -- Use a new vim.hl.on_yank() call to cancel the previous timer
exec_lua(function()
- vim.hl.range(0, ns, 'Search', { 0, 0 }, { 0, 0 }, { timeout = 0 })
+ vim.hl.on_yank({ timeout = 0, on_macro = true, event = { operator = 'y' } })
end)
end)
@@ -320,5 +320,9 @@ describe('vim.hl.on_yank', function()
{1:~ }|
|
]])
+ -- Use a new vim.hl.on_yank() call to cancel the previous timer
+ exec_lua(function()
+ vim.hl.on_yank({ timeout = 0, on_macro = true, event = { operator = 'y' } })
+ end)
end)
end)