mirror of
https://github.com/neovim/neovim.git
synced 2025-10-21 17:21:49 +00:00
test: avoid consecutive mouse input at different positions (#21781)
The seconds call's position may override the first call if the first call isn't processed yet, defeating the purpose of the first call.
This commit is contained in:
@@ -4,6 +4,7 @@ local clear, feed = helpers.clear, helpers.feed
|
|||||||
local source = helpers.source
|
local source = helpers.source
|
||||||
local command = helpers.command
|
local command = helpers.command
|
||||||
local assert_alive = helpers.assert_alive
|
local assert_alive = helpers.assert_alive
|
||||||
|
local poke_eventloop = helpers.poke_eventloop
|
||||||
local exec = helpers.exec
|
local exec = helpers.exec
|
||||||
local eval = helpers.eval
|
local eval = helpers.eval
|
||||||
local eq = helpers.eq
|
local eq = helpers.eq
|
||||||
@@ -1401,6 +1402,7 @@ describe('cmdheight=0', function()
|
|||||||
{3:[No Name] }|
|
{3:[No Name] }|
|
||||||
]])
|
]])
|
||||||
meths.input_mouse('left', 'press', '', 0, 6, 10)
|
meths.input_mouse('left', 'press', '', 0, 6, 10)
|
||||||
|
poke_eventloop()
|
||||||
meths.input_mouse('left', 'drag', '', 0, 5, 10)
|
meths.input_mouse('left', 'drag', '', 0, 5, 10)
|
||||||
screen:expect_unchanged()
|
screen:expect_unchanged()
|
||||||
end)
|
end)
|
||||||
|
@@ -1459,7 +1459,6 @@ describe('ui/ext_messages', function()
|
|||||||
feed(":set mouse=a<cr>")
|
feed(":set mouse=a<cr>")
|
||||||
meths.input_mouse('left', 'press', '', 0, 12, 10)
|
meths.input_mouse('left', 'press', '', 0, 12, 10)
|
||||||
poke_eventloop()
|
poke_eventloop()
|
||||||
meths.input_mouse('left', 'drag', '', 0, 12, 10)
|
|
||||||
meths.input_mouse('left', 'drag', '', 0, 11, 10)
|
meths.input_mouse('left', 'drag', '', 0, 11, 10)
|
||||||
feed("<c-l>")
|
feed("<c-l>")
|
||||||
feed(":set cmdheight<cr>")
|
feed(":set cmdheight<cr>")
|
||||||
|
Reference in New Issue
Block a user