diff options
author | luukvbaal <luukvbaal@gmail.com> | 2025-03-07 16:21:20 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-03-07 16:21:20 +0100 |
commit | 8da59060c6dc9899d1f66d1c9b501b80496cc2e8 (patch) | |
tree | d323d70e522c9f24fb223d498daa767c7cb82970 /test/functional/ui | |
parent | b31132f1c1fa47a9db368d5d28ee6dda8dc96ecc (diff) | |
download | rneovim-8da59060c6dc9899d1f66d1c9b501b80496cc2e8.tar.gz rneovim-8da59060c6dc9899d1f66d1c9b501b80496cc2e8.tar.bz2 rneovim-8da59060c6dc9899d1f66d1c9b501b80496cc2e8.zip |
fix(marks): mark winline as invalid if change is in a concealed line (#32766)
Code that checks whether a `w_lines` entry has become invalid due to
a change in a folded line should now also check for concealed lines.
Diffstat (limited to 'test/functional/ui')
-rw-r--r-- | test/functional/ui/decorations_spec.lua | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/functional/ui/decorations_spec.lua b/test/functional/ui/decorations_spec.lua index d680e8b96e..c0c0bf4fc1 100644 --- a/test/functional/ui/decorations_spec.lua +++ b/test/functional/ui/decorations_spec.lua @@ -2931,6 +2931,26 @@ describe('extmark decorations', function() {1:~ }|*3 | ]]) + -- Even when virtual line is added as line is concealed #32762 + feed('5G') + api.nvim_buf_clear_namespace(0, ns, 3, 4) + feed('j') + api.nvim_buf_set_extmark(0, ns, 3, 0, { virt_lines = { { { "virt_below 4" } } } }) + screen:expect([[ + {2: 1 }for _,item in ipairs(items) do | + {2: 3 } if hl_id_cell ~= nil then | + {2: 4 } hl_id = hl_id_cell | + {2: }virt_below 4 | + {2: 6 }^ for _ = 1, (count or 1) do | + {2: 7 } local cell = line[colpos] | + {2: 8 } cell.text = text | + {2: 9 } cell.hl_id = hl_id | + {2: 10 } colpos = colpos+1 | + {2: 11 } end | + {2: 12 }end | + {1:~ }|*3 + | + ]]) end) end) |