comparison src/testdir/test_terminal.vim @ 12479:65c7769ef6d1 v8.0.1119

patch 8.0.1119: quitting a split terminal window kills the job commit https://github.com/vim/vim/commit/8adb0d03ca2694922da915356d7ede05e31c5a5c Author: Bram Moolenaar <Bram@vim.org> Date: Sun Sep 17 19:08:02 2017 +0200 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.
author Christian Brabandt <cb@256bit.org>
date Sun, 17 Sep 2017 19:15:05 +0200
parents 827ad6758d33
children 5cf248ecb6e3
comparison
equal deleted inserted replaced
12478:5ffb6c77b07a 12479:65c7769ef6d1
77 exe buf . 'bwipe!' 77 exe buf . 'bwipe!'
78 call WaitFor('job_status(g:job) == "dead"') 78 call WaitFor('job_status(g:job) == "dead"')
79 call assert_equal('dead', job_status(g:job)) 79 call assert_equal('dead', job_status(g:job))
80 call assert_equal("", bufname(buf)) 80 call assert_equal("", bufname(buf))
81 81
82 unlet g:job
83 endfunc
84
85 func Test_terminal_split_quit()
86 let buf = Run_shell_in_terminal({})
87 call term_wait(buf)
88 split
89 quit!
90 call term_wait(buf)
91 sleep 50m
92 call assert_equal('run', job_status(g:job))
93
94 quit!
95 call WaitFor('job_status(g:job) == "dead"')
96 call assert_equal('dead', job_status(g:job))
97
98 exe buf . 'bwipe'
82 unlet g:job 99 unlet g:job
83 endfunc 100 endfunc
84 101
85 func Test_terminal_hide_buffer() 102 func Test_terminal_hide_buffer()
86 let buf = Run_shell_in_terminal({}) 103 let buf = Run_shell_in_terminal({})