diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2022-07-08 08:26:25 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-07-08 08:26:25 +0800 |
| commit | ca64b589cd74e9f6bd369286a415711ec7197082 (patch) | |
| tree | b394ad44b1fecd8c8f3643a3acf542bfa3e9087a /src/nvim/testdir/test_assert.vim | |
| parent | 72877bb17d70362f91a60b31bf0244dbf8ed58ae (diff) | |
| download | rneovim-ca64b589cd74e9f6bd369286a415711ec7197082.tar.gz rneovim-ca64b589cd74e9f6bd369286a415711ec7197082.tar.bz2 rneovim-ca64b589cd74e9f6bd369286a415711ec7197082.zip | |
vim-patch:8.1.{1524,1544}: tests are silently skipped (#19276)
This is a port of these two patches combined:
vim-patch:8.1.1524: tests are silently skipped
Problem: Tests are silently skipped.
Solution: Throw an exception for skipped tests in more places.
https://github.com/vim/vim/commit/b0f94c1ff34d27d33aa9f96204985ea29c2eb0a1
vim-patch:8.1.1544: some balloon tests don't run when they can
Problem: Some balloon tests don't run when they can.
Solution: Split GUI balloon tests off into a separate file. (Ozaki Kiichi,
closes vim/vim#4538) Change the feature check into a command for
consistency.
https://github.com/vim/vim/commit/b46fecd3454399f8ebdc5055302e4bfc5a10f98b
Omit test_lua.vim: previous patches are N/A
Omit test_memory_usage.vim: previous patches are N/A
Omit test_textprop.vim: previous patches are N/A
Omit test_winbar.vim: previous patches are N/A
Omit test_termcodes.vim: mostly N/A
Skip Test_mouse_positon() because it uses test_setmouse().
Cannot throw error in a Test_nocatch_ test.
Use latest `CheckFeature clipboard_working` for test_quotestar.vim
Diffstat (limited to 'src/nvim/testdir/test_assert.vim')
| -rw-r--r-- | src/nvim/testdir/test_assert.vim | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_assert.vim b/src/nvim/testdir/test_assert.vim index 28c5948142..9d0d5b3e70 100644 --- a/src/nvim/testdir/test_assert.vim +++ b/src/nvim/testdir/test_assert.vim @@ -257,6 +257,26 @@ func Test_assert_with_msg() call remove(v:errors, 0) endfunc +func Test_mouse_position() + throw 'Skipped: Nvim does not have test_setmouse()' + let save_mouse = &mouse + set mouse=a + new + call setline(1, ['line one', 'line two']) + call assert_equal([0, 1, 1, 0], getpos('.')) + call test_setmouse(1, 5) + call feedkeys("\<LeftMouse>", "xt") + call assert_equal([0, 1, 5, 0], getpos('.')) + call test_setmouse(2, 20) + call feedkeys("\<LeftMouse>", "xt") + call assert_equal([0, 2, 8, 0], getpos('.')) + call test_setmouse(5, 1) + call feedkeys("\<LeftMouse>", "xt") + call assert_equal([0, 2, 1, 0], getpos('.')) + bwipe! + let &mouse = save_mouse +endfunc + " Must be last. func Test_zz_quit_detected() " Verify that if a test function ends Vim the test script detects this. |