aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/functional/ui/decorations_spec.lua30
1 files changed, 30 insertions, 0 deletions
diff --git a/test/functional/ui/decorations_spec.lua b/test/functional/ui/decorations_spec.lua
index 930e4c3f10..9bbae0dae0 100644
--- a/test/functional/ui/decorations_spec.lua
+++ b/test/functional/ui/decorations_spec.lua
@@ -2371,6 +2371,36 @@ describe('extmark decorations', function()
|
]]}
end)
+
+ it('can replace marks in place with different decorations #27211', function()
+ local mark = api.nvim_buf_set_extmark(0, ns, 0, 0, { virt_lines = {{{"foo", "ErrorMsg"}}}, })
+ screen:expect{grid=[[
+ ^ |
+ {4:foo} |
+ {1:~ }|*12
+ |
+ ]]}
+
+ api.nvim_buf_set_extmark(0, ns, 0, 0, {
+ id = mark,
+ virt_text = { { "testing", "NonText" } },
+ virt_text_pos = "inline",
+ })
+ screen:expect{grid=[[
+ {1:^testing} |
+ {1:~ }|*13
+ |
+ ]]}
+
+ api.nvim_buf_del_extmark(0, ns, mark)
+ screen:expect{grid=[[
+ ^ |
+ {1:~ }|*13
+ |
+ ]]}
+
+ helpers.assert_alive()
+ end)
end)
describe('decorations: inline virtual text', function()