From 12bccc7dd19e55068156ec5fb55bbf960ec4aad8 Mon Sep 17 00:00:00 2001 From: Shreyansh Chouhan Date: Sun, 19 Sep 2021 22:20:24 +0530 Subject: test: close timers in vim_spec.lua functional test Close the timer started during tests before closing the session. This fixes the uv_loop_close hangs happening in the functional tests. Signed-off-by: Shreyansh Chouhan --- test/functional/lua/vim_spec.lua | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'test/functional/lua/vim_spec.lua') diff --git a/test/functional/lua/vim_spec.lua b/test/functional/lua/vim_spec.lua index a066cfbc10..f3d265cb92 100644 --- a/test/functional/lua/vim_spec.lua +++ b/test/functional/lua/vim_spec.lua @@ -2026,6 +2026,8 @@ describe('lua stdlib', function() -- Would wait ten seconds if results blocked. wait_result = vim.wait(10000, function() return vim.g.timer_result end) + timer:close() + return { time = (start_time + 5) > get_time(), wait_result = wait_result, @@ -2045,6 +2047,8 @@ describe('lua stdlib', function() wait_result = vim.wait(300, function() return vim.g.timer_result end, nil, true) + timer:close() + return { wait_result = wait_result, } -- cgit