diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-11-19 16:39:30 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-19 16:39:30 +0800 |
commit | 0958dccc6ddeca2e4ab36c1a0f444d2d5995ae99 (patch) | |
tree | b853a089df3dcacec0cd90c525cead0feaba510c | |
parent | c011747b5fc33eb7d9955c21d85085131ffaac0d (diff) | |
download | rneovim-0958dccc6ddeca2e4ab36c1a0f444d2d5995ae99.tar.gz rneovim-0958dccc6ddeca2e4ab36c1a0f444d2d5995ae99.tar.bz2 rneovim-0958dccc6ddeca2e4ab36c1a0f444d2d5995ae99.zip |
vim-patch:8.2.5130: edit test for mode message fails when using valgrind (#21118)
Problem: Edit test for mode message fails when using valgrind.
Solution: Use WaitForAssert(). Run beep test later.
https://github.com/vim/vim/commit/c5382b667ac4b69ddff5b5bc562386843bc9c07b
Co-authored-by: Bram Moolenaar <Bram@vim.org>
-rw-r--r-- | src/nvim/testdir/test_edit.vim | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/src/nvim/testdir/test_edit.vim b/src/nvim/testdir/test_edit.vim index dc850515b0..89e597f401 100644 --- a/src/nvim/testdir/test_edit.vim +++ b/src/nvim/testdir/test_edit.vim @@ -1863,11 +1863,9 @@ func Test_edit_insertmode_ex_edit() call writefile(lines, 'Xtest_edit_insertmode_ex_edit') let buf = RunVimInTerminal('-S Xtest_edit_insertmode_ex_edit', #{rows: 6}) - call TermWait(buf, 50) - call assert_match('^-- INSERT --\s*$', term_getline(buf, 6)) + call WaitForAssert({-> assert_match('^-- INSERT --\s*$', term_getline(buf, 6))}) call term_sendkeys(buf, "\<C-B>\<C-L>") - call TermWait(buf, 50) - call assert_notmatch('^-- INSERT --\s*$', term_getline(buf, 6)) + call WaitForAssert({-> assert_notmatch('^-- INSERT --\s*$', term_getline(buf, 6))}) " clean up call StopVimInTerminal(buf) @@ -1875,15 +1873,16 @@ func Test_edit_insertmode_ex_edit() endfunc " Pressing escape in 'insertmode' should beep -func Test_edit_insertmode_esc_beeps() - throw "Skipped: Nvim does not support 'insertmode'" +" FIXME: Execute this later, when using valgrind it makes the next test +" Test_edit_insertmode_ex_edit() fail. +func Test_z_edit_insertmode_esc_beeps() new - set insertmode - call assert_beeps("call feedkeys(\"one\<Esc>\", 'xt')") + " set insertmode + " call assert_beeps("call feedkeys(\"one\<Esc>\", 'xt')") set insertmode& - " unsupported CTRL-G command should beep in insert mode. + " unsupported "CTRL-G l" command should beep in insert mode. call assert_beeps("normal i\<C-G>l") - close! + bwipe! endfunc " Test for 'hkmap' and 'hkmapp' |