aboutsummaryrefslogtreecommitdiff
path: root/test/functional/api/window_spec.lua
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/api/window_spec.lua')
-rw-r--r--test/functional/api/window_spec.lua10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/functional/api/window_spec.lua b/test/functional/api/window_spec.lua
index 8966c3b086..e0cb66de41 100644
--- a/test/functional/api/window_spec.lua
+++ b/test/functional/api/window_spec.lua
@@ -1571,6 +1571,16 @@ describe('API/win', function()
)
eq(false, eval('fired'))
end)
+
+ it('fires Buf* autocommands when `!enter` if window is entered via autocommands', function()
+ exec([[
+ autocmd WinNew * ++once only!
+ let fired = v:false
+ autocmd BufEnter * ++once let fired = v:true
+ ]])
+ api.nvim_open_win(api.nvim_create_buf(true, true), false, { split = 'left' })
+ eq(true, eval('fired'))
+ end)
end)
describe('set_config', function()