diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2017-03-29 23:15:07 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-29 23:15:07 +0200 |
commit | c60e409471c51864883bd0b874980d0a8857f813 (patch) | |
tree | 64444c3f0210461e398654e3d6dd6f00e0091cd9 /test/helpers.lua | |
parent | c35420558bed0bfa9938ecd1facec88f1df392a5 (diff) | |
parent | 46efe14473fa803f84509592cc1e8fca4eb20640 (diff) | |
download | rneovim-c60e409471c51864883bd0b874980d0a8857f813.tar.gz rneovim-c60e409471c51864883bd0b874980d0a8857f813.tar.bz2 rneovim-c60e409471c51864883bd0b874980d0a8857f813.zip |
Merge #5119 from ZyX-I/split-eval
Diffstat (limited to 'test/helpers.lua')
-rw-r--r-- | test/helpers.lua | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/helpers.lua b/test/helpers.lua index e5224349c2..1a86effa1c 100644 --- a/test/helpers.lua +++ b/test/helpers.lua @@ -225,6 +225,19 @@ local function which(exe) end end +local function concat_tables(...) + local ret = {} + for i = 1, select('#', ...) do + local tbl = select(i, ...) + if tbl then + for _, v in ipairs(tbl) do + ret[#ret + 1] = v + end + end + end + return ret +end + return { eq = eq, neq = neq, @@ -238,4 +251,5 @@ return { check_cores = check_cores, hasenv = hasenv, which = which, + concat_tables = concat_tables, } |