From 37316fbac641ecafde29fd750a08ece490d209c1 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sun, 12 Jan 2025 08:04:25 +0800 Subject: vim-patch:9.1.1005: completion text is highlighted even with no pattern found (#31973) Problem: completion text is highlighted even with no pattern found Solution: use ins_compl_leader_len() instead of checking compl_leader.length (glepnir) closes: vim/vim#16422 https://github.com/vim/vim/commit/9fddb8ae770be3e16545dd4c2f4cfaad8f62cb40 Co-authored-by: glepnir --- test/functional/ui/popupmenu_spec.lua | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'test/functional/ui/popupmenu_spec.lua') diff --git a/test/functional/ui/popupmenu_spec.lua b/test/functional/ui/popupmenu_spec.lua index 66b62341a9..b763f4ba6c 100644 --- a/test/functional/ui/popupmenu_spec.lua +++ b/test/functional/ui/popupmenu_spec.lua @@ -5885,7 +5885,16 @@ describe('builtin popupmenu', function() {1:~ }|*17 {2:-- }{5:match 1 of 3} | ]]) - feed('') + feed('') + + command('set cot-=fuzzy') + feed('Sf') + screen:expect([[ + {10:f^ }| + {1:~ }|*18 + {2:-- }{6:Pattern not found} | + ]]) + feed('') end) end end -- cgit