comparison src/testdir/test_terminal.vim @ 19770:4e843fc8772f v8.2.0441

patch 8.2.0441: terminal noblock test is still failing on BSD Commit: https://github.com/vim/vim/commit/f3710ee22d0039cea2f970452b5faf56e89a6ab0 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Mar 24 12:12:30 2020 +0100 patch 8.2.0441: terminal noblock test is still failing on BSD Problem: Terminal noblock test is still failing on BSD. Solution: Reduce the amount of text.
author Bram Moolenaar <Bram@vim.org>
date Tue, 24 Mar 2020 12:15:04 +0100
parents 0d1088e3c53f
children cadb4c1bee6e
comparison
equal deleted inserted replaced
19769:6679844938dc 19770:4e843fc8772f
660 call assert_equal("", bufname(buf)) 660 call assert_equal("", bufname(buf))
661 endfunction 661 endfunction
662 662
663 func Test_terminal_noblock() 663 func Test_terminal_noblock()
664 let buf = term_start(&shell) 664 let buf = term_start(&shell)
665 let wait_time = 5000
666 let letters = 'abcdefghijklmnopqrstuvwxyz'
665 if has('bsd') || has('mac') || has('sun') 667 if has('bsd') || has('mac') || has('sun')
666 " The shell or something else has a problem dealing with more than 1000 668 " The shell or something else has a problem dealing with more than 1000
667 " characters at the same time. 669 " characters at the same time. It's very slow too.
668 let len = 1000 670 let len = 1000
669 let wait_time = 15000 671 let wait_time = 15000
672 let letters = 'abcdefghijklm'
670 " NPFS is used in Windows, nonblocking mode does not work properly. 673 " NPFS is used in Windows, nonblocking mode does not work properly.
671 elseif has('win32') 674 elseif has('win32')
672 let len = 1 675 let len = 1
673 let wait_time = 5000
674 else 676 else
675 let len = 5000 677 let len = 5000
676 let wait_time = 5000
677 endif 678 endif
678 679
679 " Send a lot of text lines, should be buffered properly. 680 " Send a lot of text lines, should be buffered properly.
680 for c in split('abcdefghijklmnopqrstuvwxyz', '\zs') 681 for c in split(letters, '\zs')
681 call term_sendkeys(buf, 'echo ' . repeat(c, len) . "\<cr>") 682 call term_sendkeys(buf, 'echo ' . repeat(c, len) . "\<cr>")
682 endfor 683 endfor
683 call term_sendkeys(buf, "echo done\<cr>") 684 call term_sendkeys(buf, "echo done\<cr>")
684 685
685 " On MS-Windows there is an extra empty line below "done". Find "done" in 686 " On MS-Windows there is an extra empty line below "done". Find "done" in