diff options
author | Bram Moolenaar <Bram@vim.org> | 2017-08-20 19:33:47 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2017-08-20 19:33:47 +0200 |
commit | 37819ed54064b949b1f205c9f4084ba32e3db8bc (patch) | |
tree | 729df977aaac55450e99b70c07ee90eecb286542 | |
parent | 5983d5024711f078e7261264cb0e7d6e57953968 (diff) | |
download | vim-git-37819ed54064b949b1f205c9f4084ba32e3db8bc.tar.gz |
patch 8.0.0978: writing to terminal job is not testedv8.0.0978
Problem: Writing to terminal job is not tested.
Solution: Add a test.
-rw-r--r-- | src/testdir/test_terminal.vim | 23 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 25 insertions, 0 deletions
diff --git a/src/testdir/test_terminal.vim b/src/testdir/test_terminal.vim index a4041d725..b3868553e 100644 --- a/src/testdir/test_terminal.vim +++ b/src/testdir/test_terminal.vim @@ -470,3 +470,26 @@ func Test_terminal_noblock() unlet g:lnum bwipe endfunc + +func Test_terminal_write_stdin() + " Todo: make this work on all systems. + if !has('unix') + return + endif + new + call setline(1, ['one', 'two', 'three']) + %term wc + call WaitFor('getline(1) != ""') + let nrs = split(getline(1)) + call assert_equal(['3', '3', '14'], nrs) + bwipe + + call setline(1, ['one', 'two', 'three', 'four']) + 2,3term wc + call WaitFor('getline(1) != ""') + let nrs = split(getline(1)) + call assert_equal(['2', '2', '10'], nrs) + bwipe + + bwipe! +endfunc diff --git a/src/version.c b/src/version.c index 432849f48..0488c199d 100644 --- a/src/version.c +++ b/src/version.c @@ -770,6 +770,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 978, +/**/ 977, /**/ 976, |