aboutsummaryrefslogtreecommitdiff
path: root/test/functional/helpers.lua
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/helpers.lua')
-rw-r--r--test/functional/helpers.lua11
1 files changed, 10 insertions, 1 deletions
diff --git a/test/functional/helpers.lua b/test/functional/helpers.lua
index 393b42dda5..27c94c34a8 100644
--- a/test/functional/helpers.lua
+++ b/test/functional/helpers.lua
@@ -18,6 +18,10 @@ if nvim_dir == nvim_prog then
nvim_dir = "."
end
+-- Nvim "Unit Under Test" http://en.wikipedia.org/wiki/Device_under_test
+local NvimUUT = {}
+NvimUUT.__index = NvimUUT
+
local prepend_argv
if os.getenv('VALGRIND') then
@@ -49,6 +53,10 @@ end
local session, loop_running, loop_stopped, last_error
+local function set_session(s)
+ session = s
+end
+
local function request(method, ...)
local status, rv = session:request(method, ...)
if not status then
@@ -305,5 +313,6 @@ return {
curwin = curwin,
curtab = curtab,
curbuf_contents = curbuf_contents,
- wait = wait
+ wait = wait,
+ set_session = set_session
}