mirror of
https://github.com/neovim/neovim.git
synced 2025-10-04 08:56:29 +00:00
vim-patch:8.2.0874: signals test is a bit flaky
Problem: Signals test is a bit flaky.
Solution: Flush the XautoOut file. Delete files that may be left behind
from a failure. (Dominique Pelle, closes vim/vim#6179)
d14fd5285e
This commit is contained in:
@@ -98,9 +98,15 @@ func Test_deadly_signal_TERM()
|
||||
if cmd =~ 'valgrind'
|
||||
throw 'Skipped: cannot test signal TERM with valgrind'
|
||||
endif
|
||||
|
||||
" If test fails once, it can leave temporary files and trying to rerun
|
||||
" the test would then fail again if they are not deleted first.
|
||||
call delete('.Xsig_TERM.swp')
|
||||
call delete('XsetupAucmd')
|
||||
call delete('XautoOut')
|
||||
let lines =<< trim END
|
||||
au VimLeave * call writefile(["VimLeave triggered"], "XautoOut", "a")
|
||||
au VimLeavePre * call writefile(["VimLeavePre triggered"], "XautoOut", "a")
|
||||
au VimLeave * call writefile(["VimLeave triggered"], "XautoOut", "as")
|
||||
au VimLeavePre * call writefile(["VimLeavePre triggered"], "XautoOut", "as")
|
||||
END
|
||||
call writefile(lines, 'XsetupAucmd')
|
||||
|
||||
|
Reference in New Issue
Block a user