aboutsummaryrefslogtreecommitdiff
path: root/test/old/testdir/test_normal.vim
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2024-03-29 17:49:25 +0800
committerGitHub <noreply@github.com>2024-03-29 17:49:25 +0800
commitd223a7cbd2a204fffeb220fb18dfede8f4ef3e1f (patch)
tree1628d511042651d891a5437680450634bd6da631 /test/old/testdir/test_normal.vim
parentb1615a35f08ae3073f7d2e4e8e080907f0d48e92 (diff)
downloadrneovim-d223a7cbd2a204fffeb220fb18dfede8f4ef3e1f.tar.gz
rneovim-d223a7cbd2a204fffeb220fb18dfede8f4ef3e1f.tar.bz2
rneovim-d223a7cbd2a204fffeb220fb18dfede8f4ef3e1f.zip
vim-patch:9.1.0228: Two unrelated things are tested by a single test (#28093)
Problem: Two unrelated things are tested by a single test. Solution: Split it into two, restoring the old Test_brace_single_line(). Add missing cleanup to some tests. (zeertzjq) closes: vim/vim#14323 https://github.com/vim/vim/commit/ad493ef3ea9ef7f2b0badcd2298883b5ab6e4ef4
Diffstat (limited to 'test/old/testdir/test_normal.vim')
-rw-r--r--test/old/testdir/test_normal.vim23
1 files changed, 16 insertions, 7 deletions
diff --git a/test/old/testdir/test_normal.vim b/test/old/testdir/test_normal.vim
index 937f18aa69..26270fddd2 100644
--- a/test/old/testdir/test_normal.vim
+++ b/test/old/testdir/test_normal.vim
@@ -4184,21 +4184,29 @@ func Test_normal34_zet_large()
norm! z9765405999999999999
endfunc
-" Test for { and } paragraph movements and Ctrl-B in buffer with a single line
-func Test_single_line_scroll()
- CheckFeature textprop
-
+" Test for { and } paragraph movements in a single line
+func Test_brace_single_line()
new
call setline(1, ['foobar one two three'])
- let vt = 'virt_above'
- call prop_type_add(vt, {'highlight': 'IncSearch'})
- call prop_add(1, 0, {'type': vt, 'text': '---', 'text_align': 'above'})
1
norm! 0}
call assert_equal([0, 1, 20, 0], getpos('.'))
norm! {
call assert_equal([0, 1, 1, 0], getpos('.'))
+ bw!
+endfunc
+
+" Test for Ctrl-B/Ctrl-U in buffer with a single line
+func Test_single_line_scroll()
+ CheckFeature textprop
+
+ new
+ call setline(1, ['foobar one two three'])
+ let vt = 'virt_above'
+ call prop_type_add(vt, {'highlight': 'IncSearch'})
+ call prop_add(1, 0, {'type': vt, 'text': '---', 'text_align': 'above'})
+ call cursor(1, 1)
" Ctrl-B/Ctrl-U scroll up with hidden "above" virtual text.
set smoothscroll
@@ -4213,6 +4221,7 @@ func Test_single_line_scroll()
set smoothscroll&
bw!
+ call prop_type_delete(vt)
endfunc
" vim: shiftwidth=2 sts=2 expandtab nofoldenable