neovim/test/functional/legacy/search_mbyte_spec.lua
Björn Linse 07cc231142 A Mudholland Dr. Recast
The commit summary maybe does not make sense, but calling a function
that does not wait on anything `wait()` makes even less sense.
2020-10-19 21:48:06 +02:00

32 lines
622 B
Lua
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

local helpers = require('test.functional.helpers')(after_each)
local poke_eventloop = helpers.poke_eventloop
local clear = helpers.clear
local insert = helpers.insert
local expect = helpers.expect
local command = helpers.command
describe('search_mbyte', function()
before_each(clear)
it("search('multi-byte char', 'bce')", function()
insert([=[
Results:
Test bce:
]=])
poke_eventloop()
command('/^Test bce:/+1')
command([[$put =search('', 'bce', line('.'))]])
-- Assert buffer contents.
expect([=[
Results:
Test bce:
4]=])
end)
end)