commit 1c16e5bb1105e1e0b668d5acb7830c69b78fec0e
parent 254454d0c5a92acaa2c7d199236c216a9de8b6ee
Author: zeertzjq <zeertzjq@outlook.com>
Date: Mon, 13 Jun 2022 16:05:15 +0800
vim-patch:8.2.5081: autocmd test fails on MS-Windows
Problem: Autocmd test fails on MS-Windows.
Solution: Set shellslash to get forward slashes.
https://github.com/vim/vim/commit/7c0d0c3c75151e716184397a41ff74ab0429db5a
Diffstat:
1 file changed, 3 insertions(+), 0 deletions(-)
diff --git a/src/nvim/testdir/test_autocmd.vim b/src/nvim/testdir/test_autocmd.vim
@@ -1982,12 +1982,15 @@ function Test_dirchanged_global()
exe 'lcd ' .. fnameescape(s:dir_bar)
call assert_equal(expected, s:li)
+ let save_shellslash = &shellslash
+ set shellslash
exe 'cd ' .. s:dir_foo
exe 'cd ' .. s:dir_bar
autocmd! test_dirchanged DirChanged global let g:result = expand("<afile>")
cd -
call assert_equal(s:dir_foo, g:result)
+ let &shellslash = save_shellslash
call s:After_test_dirchanged()
endfunc