diff options
Diffstat (limited to 'test/functional/ui/decorations_spec.lua')
-rw-r--r-- | test/functional/ui/decorations_spec.lua | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/functional/ui/decorations_spec.lua b/test/functional/ui/decorations_spec.lua index 1709819575..61a5e1d6f7 100644 --- a/test/functional/ui/decorations_spec.lua +++ b/test/functional/ui/decorations_spec.lua @@ -5620,6 +5620,27 @@ l5 ]] }) end) + + it('supports emoji as signs', function() + insert(example_test3) + feed 'gg' + api.nvim_buf_set_extmark(0, ns, 1, 0, {sign_text='🧑🌾'}) + -- VS16 can change width of character + api.nvim_buf_set_extmark(0, ns, 2, 0, {sign_text='❤️'}) + api.nvim_buf_set_extmark(0, ns, 3, 0, {sign_text='❤'}) + api.nvim_buf_set_extmark(0, ns, 4, 0, {sign_text='❤x'}) + screen:expect([[ + {7: }^l1 | + 🧑🌾l2 | + ❤️l3 | + ❤ l4 | + ❤xl5 | + {7: } | + {1:~ }|*3 + | + ]]) + eq("Invalid 'sign_text'", pcall_err(api.nvim_buf_set_extmark, 0, ns, 5, 0, {sign_text='❤️x'})) + end) end) describe('decorations: virt_text', function() |