Patch 8.1.1677
Problem: Tests get stuck when running into an existing swapfile.
Solution: Set v:swapchoice to "q" and report an error. (Daniel Hahler,
closes #4644)
Files: src/testdir/runtest.vim
*** ../vim-8.1.1676/src/testdir/runtest.vim 2019-06-16 22:54:10.649908500 +0200
--- src/testdir/runtest.vim 2019-07-13 14:33:43.470108589 +0200
***************
*** 68,77 ****
let s:test_script_fname = expand('%')
au! SwapExists * call HandleSwapExists()
func HandleSwapExists()
! " Only ignore finding a swap file for the test script (the user might be
" editing it and do ":make test_name") and the output file.
if expand('<afile>') == 'messages' || expand('<afile>') =~ s:test_script_fname
let v:swapchoice = 'e'
endif
endfunc
--- 68,81 ----
let s:test_script_fname = expand('%')
au! SwapExists * call HandleSwapExists()
func HandleSwapExists()
! " Ignore finding a swap file for the test script (the user might be
" editing it and do ":make test_name") and the output file.
+ " Report finding another swap file and chose 'q' to avoid getting stuck.
if expand('<afile>') == 'messages' || expand('<afile>') =~ s:test_script_fname
let v:swapchoice = 'e'
+ else
+ call assert_report('Unexpected swap file: ' .. v:swapname)
+ let v:swapchoice = 'q'
endif
endfunc
*** ../vim-8.1.1676/src/version.c 2019-07-13 14:17:34.505914114 +0200
--- src/version.c 2019-07-13 14:42:24.956610776 +0200
***************
*** 779,780 ****
--- 779,782 ----
{ /* Add new patch number below this line */
+ /**/
+ 1677,
/**/
--
Q: What do you call a fish without an eye?
A: fsh!
Q: What do you call a deer with no eyes?
A: no eye deer.
Q: What do you call a deer with no eyes and no legs?
A: still no eye deer.
/// Bram Moolenaar -- Br...@Moolenaar.net --
http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features --
http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language --
http://www.Zimbu.org ///
\\\ help me help AIDS victims --
http://ICCF-Holland.org ///