forked from aniani/vim
patch 8.0.1119: quitting a split terminal window kills the job
Problem: Quitting a split terminal window kills the job. (Yasuhiro Matsumoto) Solution: Only stop terminal job if it is the last window.
This commit is contained in:
@@ -82,6 +82,23 @@ func Test_terminal_wipe_buffer()
|
||||
unlet g:job
|
||||
endfunc
|
||||
|
||||
func Test_terminal_split_quit()
|
||||
let buf = Run_shell_in_terminal({})
|
||||
call term_wait(buf)
|
||||
split
|
||||
quit!
|
||||
call term_wait(buf)
|
||||
sleep 50m
|
||||
call assert_equal('run', job_status(g:job))
|
||||
|
||||
quit!
|
||||
call WaitFor('job_status(g:job) == "dead"')
|
||||
call assert_equal('dead', job_status(g:job))
|
||||
|
||||
exe buf . 'bwipe'
|
||||
unlet g:job
|
||||
endfunc
|
||||
|
||||
func Test_terminal_hide_buffer()
|
||||
let buf = Run_shell_in_terminal({})
|
||||
setlocal bufhidden=hide
|
||||
|
Reference in New Issue
Block a user