diff options
author | chentau <tchen1998@gmail.com> | 2021-02-07 13:50:29 -0800 |
---|---|---|
committer | chentau <tchen1998@gmail.com> | 2021-02-07 13:50:29 -0800 |
commit | 05605bfc05054fa7bbeb5ed2412e5ef58721cfa4 (patch) | |
tree | a6283000c35d8bd032b5b233d6052081069239b9 /test/functional/api/buffer_spec.lua | |
parent | 336eb70822970cea6797251043158ee6bd76bc69 (diff) | |
download | rneovim-05605bfc05054fa7bbeb5ed2412e5ef58721cfa4.tar.gz rneovim-05605bfc05054fa7bbeb5ed2412e5ef58721cfa4.tar.bz2 rneovim-05605bfc05054fa7bbeb5ed2412e5ef58721cfa4.zip |
correctly mark changed regions for set_text
Diffstat (limited to 'test/functional/api/buffer_spec.lua')
-rw-r--r-- | test/functional/api/buffer_spec.lua | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/functional/api/buffer_spec.lua b/test/functional/api/buffer_spec.lua index fb8ed6a9d7..81fad206da 100644 --- a/test/functional/api/buffer_spec.lua +++ b/test/functional/api/buffer_spec.lua @@ -513,6 +513,28 @@ describe('api/buf', function() eq({0, 8}, curbufmeths.get_extmark_by_id(ns, id2, {})) eq({0, 8}, curbufmeths.get_extmark_by_id(ns, id3, {})) end) + + it("correctly marks changed region for redraw #13890", function() + local screen = Screen.new(20, 5) + screen:attach() + + insert([[ + AAA + BBB + ]]) + + curbufmeths.set_text(0, 0, 1, 3, {'XXX', 'YYY'}) + + screen:expect([[ + XXX | + YYY | + ^ | + ~ | + | + + ]]) + + end) end) describe('nvim_buf_get_offset', function() |