aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-05-18 16:07:16 +0800
committerGitHub <noreply@github.com>2022-05-18 16:07:16 +0800
commit93d24a63b2c378f41a04d181a7863264b985e7b4 (patch)
treeb400a7545c015cae5bef90e2bc0f71877021a154 /test
parent6e414b698cbcc4f1e42564febad030d1a0a52230 (diff)
downloadrneovim-93d24a63b2c378f41a04d181a7863264b985e7b4.tar.gz
rneovim-93d24a63b2c378f41a04d181a7863264b985e7b4.tar.bz2
rneovim-93d24a63b2c378f41a04d181a7863264b985e7b4.zip
test: fix mksession terminal CWD test again (#18615)
Diffstat (limited to 'test')
-rw-r--r--test/functional/ex_cmds/mksession_spec.lua7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/functional/ex_cmds/mksession_spec.lua b/test/functional/ex_cmds/mksession_spec.lua
index 68034efad6..97e41bbe83 100644
--- a/test/functional/ex_cmds/mksession_spec.lua
+++ b/test/functional/ex_cmds/mksession_spec.lua
@@ -10,6 +10,7 @@ local funcs = helpers.funcs
local matches = helpers.matches
local pesc = helpers.pesc
local rmdir = helpers.rmdir
+local sleep = helpers.sleep
local file_prefix = 'Xtest-functional-ex_cmds-mksession_spec'
@@ -102,9 +103,11 @@ describe(':mksession', function()
local session_path = cwd_dir..'/'..session_file
command('cd '..tab_dir)
- command('terminal echo $PWD')
+ command('terminal')
command('cd '..cwd_dir)
command('mksession '..session_path)
+ command('bd!')
+ sleep(100) -- Make sure the process exits.
command('qall!')
-- Create a new test instance of Nvim.
@@ -113,5 +116,7 @@ describe(':mksession', function()
local expected_cwd = cwd_dir..'/'..tab_dir
matches('^term://'..pesc(expected_cwd)..'//%d+:', funcs.expand('%'))
+ command('bd!')
+ sleep(100) -- Make sure the process exits.
end)
end)