test: Lua 5.2/5.3 compat #9280

Make the code run both on Lua 5.1 (which is the default for Neovim, and
is what LuaJIT provides) and Lua 5.2+.
This commit is contained in:
Matěj Cepl
2018-11-27 16:29:43 +01:00
committed by Justin M. Keyes
parent ccb005b9e0
commit e6d0dea42b
15 changed files with 15 additions and 0 deletions

View File

@@ -2,6 +2,7 @@
-- `rpcrequest` calls we need the client event loop to be running.
local helpers = require('test.functional.helpers')(after_each)
local Paths = require('test.config.paths')
local unpack = table.unpack or unpack -- luacheck: ignore
local clear, nvim, eval = helpers.clear, helpers.nvim, helpers.eval
local eq, neq, run, stop = helpers.eq, helpers.neq, helpers.run, helpers.stop