diff options
Diffstat (limited to 'src/testdir/test_autocmd.vim')
-rw-r--r-- | src/testdir/test_autocmd.vim | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/testdir/test_autocmd.vim b/src/testdir/test_autocmd.vim index be73c18197..6e1223275f 100644 --- a/src/testdir/test_autocmd.vim +++ b/src/testdir/test_autocmd.vim @@ -2706,6 +2706,24 @@ func Test_TextChangedI_with_setline() bwipe! endfunc +func Test_TextChanged_with_norm() + " For unknown reason this fails on MS-Windows + CheckNotMSWindows + CheckFeature terminal + let buf = term_start([GetVimProg(), '--clean', '-c', 'set noswapfile'], {'term_rows': 3}) + call assert_equal('running', term_getstatus(buf)) + call term_sendkeys(buf, ":let g:a=0\<cr>") + call term_wait(buf, 50) + call term_sendkeys(buf, ":au! TextChanged * :let g:a+=1\<cr>") + call term_wait(buf, 50) + call term_sendkeys(buf, ":norm! ia\<cr>") + call term_wait(buf, 50) + call term_sendkeys(buf, ":echo g:a\<cr>") + call term_wait(buf, 50) + call WaitForAssert({-> assert_match('^1.*$', term_getline(buf, 3))}) + bwipe! +endfunc + func Test_Changed_FirstTime() CheckFeature terminal CheckNotGui |