diff options
author | Christian Brabandt <cb@256bit.org> | 2021-11-03 22:31:44 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2021-11-03 22:31:44 +0000 |
commit | 4b2c8047679b737dcb0cd15c313ee51553aed617 (patch) | |
tree | 90434a083c038a7798d1fdbe56932683f8020811 /src/testdir/runtest.vim | |
parent | b32aa8a6a10983836d5987f1e42035f88d47bf6e (diff) | |
download | vim-git-4b2c8047679b737dcb0cd15c313ee51553aed617.tar.gz |
patch 8.2.3579: CI sometimes fails for MinGWv8.2.3579
Problem: CI sometimes fails for MinGW.
Solution: Use backslashes in HandleSwapExists(). (Christian Brabandt,
closes #9078)
Diffstat (limited to 'src/testdir/runtest.vim')
-rw-r--r-- | src/testdir/runtest.vim | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/testdir/runtest.vim b/src/testdir/runtest.vim index cc45393da..cd3683906 100644 --- a/src/testdir/runtest.vim +++ b/src/testdir/runtest.vim @@ -93,7 +93,12 @@ set encoding=utf-8 " REDIR_TEST_TO_NULL has a very permissive SwapExists autocommand which is for " the test_name.vim file itself. Replace it here with a more restrictive one, " so we still catch mistakes. -let s:test_script_fname = expand('%') +if has("win32") + " replace any '/' directory separators by '\\' + let s:test_script_fname = substitute(expand('%'), '/', '\\', 'g') +else + let s:test_script_fname = expand('%') +endif au! SwapExists * call HandleSwapExists() func HandleSwapExists() if exists('g:ignoreSwapExists') |