diff options
author | Matthieu Coudron <matthieu.coudron@upmc.fr> | 2017-02-28 09:34:02 +0100 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2017-02-28 09:34:02 +0100 |
commit | 5ed753044d650e7c2c0b65f0b04831097078d48a (patch) | |
tree | 2bf853af6165322539a442afb34c96c9cd72c4a8 /test/functional/helpers.lua | |
parent | e0705021c10cba81d71de79de2f8bbebecd121a1 (diff) | |
download | rneovim-5ed753044d650e7c2c0b65f0b04831097078d48a.tar.gz rneovim-5ed753044d650e7c2c0b65f0b04831097078d48a.tar.bz2 rneovim-5ed753044d650e7c2c0b65f0b04831097078d48a.zip |
test: Refactor fold tests (#5993)
Diffstat (limited to 'test/functional/helpers.lua')
-rw-r--r-- | test/functional/helpers.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/functional/helpers.lua b/test/functional/helpers.lua index 65d1ad76ef..44fff0e9a7 100644 --- a/test/functional/helpers.lua +++ b/test/functional/helpers.lua @@ -435,6 +435,11 @@ local function expect(contents) return eq(dedent(contents), curbuf_contents()) end +local function expect_any(contents) + contents = dedent(contents) + return ok(nil ~= string.find(curbuf_contents(), contents, 1, true)) +end + local function do_rmdir(path) if lfs.attributes(path, 'mode') ~= 'directory' then return nil @@ -585,6 +590,7 @@ local M = { eq = eq, neq = neq, expect = expect, + expect_any = expect_any, ok = ok, map = map, filter = filter, |