aboutsummaryrefslogtreecommitdiff
path: root/test/functional/ui/linematch_spec.lua
diff options
context:
space:
mode:
authorJosh Rahm <joshuarahm@gmail.com>2025-02-05 23:09:29 +0000
committerJosh Rahm <joshuarahm@gmail.com>2025-02-05 23:09:29 +0000
commitd5f194ce780c95821a855aca3c19426576d28ae0 (patch)
treed45f461b19f9118ad2bb1f440a7a08973ad18832 /test/functional/ui/linematch_spec.lua
parentc5d770d311841ea5230426cc4c868e8db27300a8 (diff)
parent44740e561fc93afe3ebecfd3618bda2d2abeafb0 (diff)
downloadrneovim-d5f194ce780c95821a855aca3c19426576d28ae0.tar.gz
rneovim-d5f194ce780c95821a855aca3c19426576d28ae0.tar.bz2
rneovim-d5f194ce780c95821a855aca3c19426576d28ae0.zip
Merge remote-tracking branch 'upstream/master' into mix_20240309HEADrahm
Diffstat (limited to 'test/functional/ui/linematch_spec.lua')
-rw-r--r--test/functional/ui/linematch_spec.lua28
1 files changed, 28 insertions, 0 deletions
diff --git a/test/functional/ui/linematch_spec.lua b/test/functional/ui/linematch_spec.lua
index b564c01eaa..3593604c49 100644
--- a/test/functional/ui/linematch_spec.lua
+++ b/test/functional/ui/linematch_spec.lua
@@ -1147,4 +1147,32 @@ describe('regressions', function()
},
}
end)
+
+ -- oldtest: Test_linematch_3diffs_sanity_check()
+ it('sanity check with 3 diff buffers', function()
+ clear()
+ screen = Screen.new(75, 20)
+ n.api.nvim_buf_set_lines(0, 0, -1, false, { 'abcd', 'def', 'hij' })
+ n.exec('rightbelow vnew')
+ n.api.nvim_buf_set_lines(0, 0, -1, false, { 'defq', 'hijk', 'nopq' })
+ n.exec('rightbelow vnew')
+ n.api.nvim_buf_set_lines(0, 0, -1, false, { 'hijklm', 'nopqr', 'stuv' })
+ n.exec([[
+ set diffopt+=linematch:60
+ windo diffthis | wincmd t
+ call feedkeys("Aq\<esc>")
+ call feedkeys("GAklm\<esc>")
+ call feedkeys("o")
+ ]])
+ screen:expect([[
+ {7: }{22:abcdq }│{7: }{23:----------------------}│{7: }{23:-----------------------}|
+ {7: }{4:def }│{7: }{4:def}{27:q}{4: }│{7: }{23:-----------------------}|
+ {7: }{4:hijk}{27:lm}{4: }│{7: }{4:hijk }│{7: }{4:hijk}{27:lm}{4: }|
+ {7: }{23:----------------------}│{7: }{4:nopq }│{7: }{4:nopq}{27:r}{4: }|
+ {7: }{4:^ }│{7: }{23:----------------------}│{7: }{27:stuv}{4: }|
+ {1:~ }│{1:~ }│{1:~ }|*13
+ {3:[No Name] [+] }{2:[No Name] [+] [No Name] [+] }|
+ {5:-- INSERT --} |
+ ]])
+ end)
end)