diff options
author | Luuk van Baal <luukvbaal@gmail.com> | 2023-12-08 05:58:29 +0100 |
---|---|---|
committer | Lewis Russell <me@lewisr.dev> | 2023-12-08 15:42:18 +0000 |
commit | 2289ca273cdaad4248a6cd962bddcc956b296c18 (patch) | |
tree | f18c939b8c394a65e3cc82c826ec772dd042ca65 /test | |
parent | 808fbe67a81da028eed6607fa3f5d13547d72332 (diff) | |
download | rneovim-2289ca273cdaad4248a6cd962bddcc956b296c18.tar.gz rneovim-2289ca273cdaad4248a6cd962bddcc956b296c18.tar.bz2 rneovim-2289ca273cdaad4248a6cd962bddcc956b296c18.zip |
perf(column): avoid counting when max signs are removed from a range
Diffstat (limited to 'test')
-rw-r--r-- | test/functional/ui/decorations_spec.lua | 15 | ||||
-rw-r--r-- | test/functional/ui/sign_spec.lua | 7 |
2 files changed, 19 insertions, 3 deletions
diff --git a/test/functional/ui/decorations_spec.lua b/test/functional/ui/decorations_spec.lua index a60562380a..925243054c 100644 --- a/test/functional/ui/decorations_spec.lua +++ b/test/functional/ui/decorations_spec.lua @@ -4989,6 +4989,21 @@ l5 | ]]} end) + + it('correct width with multiple overlapping signs', function() + screen:try_resize(20, 4) + insert(example_test3) + meths.buf_set_extmark(0, ns, 0, -1, {sign_text='S1', end_row=2}) + meths.buf_set_extmark(0, ns, 1, -1, {sign_text='S2', end_row=2}) + feed('gg') + + screen:expect{grid=[[ + S1{1: }^l1 | + S1S2l2 | + S1S2l3 | + | + ]]} + end) end) describe('decorations: virt_text', function() diff --git a/test/functional/ui/sign_spec.lua b/test/functional/ui/sign_spec.lua index b12e79bd42..1c0a6f663b 100644 --- a/test/functional/ui/sign_spec.lua +++ b/test/functional/ui/sign_spec.lua @@ -367,11 +367,12 @@ describe('Signs', function() | ]]} -- line deletion deletes signs. + command('3move1') command('2d') screen:expect([[ - {1:>>}{8:XX}{2: }{6: 1 }a | - {8:XX}{1:>>}WW{6: 2 }^c | - {2: }{6: 3 } | + {1:>>}{8:XX}{6: 1 }a | + {8:XX}{1:>>}{6: 2 }^b | + {2: }{6: 3 } | {0:~ }| {0:~ }| {0:~ }| |