diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2017-04-09 22:51:59 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-09 22:51:59 +0200 |
commit | d7fb7de70aee3dff48abc61986818dee86afed07 (patch) | |
tree | a9263b8deb57161f2b5315117371af026759c79b /test/functional/helpers.lua | |
parent | dbdd69e418a3baa4750abc25fae7516a36776e75 (diff) | |
parent | dbe67868b53774443521129ef30d74346592e3bb (diff) | |
download | rneovim-d7fb7de70aee3dff48abc61986818dee86afed07.tar.gz rneovim-d7fb7de70aee3dff48abc61986818dee86afed07.tar.bz2 rneovim-d7fb7de70aee3dff48abc61986818dee86afed07.zip |
Merge #6481 from ZyX-I/rename-execute
Rename execute() function to feed_command()
Diffstat (limited to 'test/functional/helpers.lua')
-rw-r--r-- | test/functional/helpers.lua | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/test/functional/helpers.lua b/test/functional/helpers.lua index 42ed1800d3..13b06e7f1b 100644 --- a/test/functional/helpers.lua +++ b/test/functional/helpers.lua @@ -8,6 +8,7 @@ local Session = require('nvim.session') local TcpStream = require('nvim.tcp_stream') local SocketStream = require('nvim.socket_stream') local ChildProcessStream = require('nvim.child_process_stream') +local Paths = require('test.config.paths') local check_cores = global_helpers.check_cores local check_logs = global_helpers.check_logs @@ -20,7 +21,11 @@ local dedent = global_helpers.dedent local start_dir = lfs.currentdir() -- XXX: NVIM_PROG takes precedence, QuickBuild sets it. -local nvim_prog = os.getenv('NVIM_PROG') or os.getenv('NVIM_PRG') or 'build/bin/nvim' +local nvim_prog = ( + os.getenv('NVIM_PROG') + or os.getenv('NVIM_PRG') + or Paths.test_build_dir .. '/bin/nvim' +) -- Default settings for the test session. local nvim_set = 'set shortmess+=I background=light noswapfile noautoindent' ..' laststatus=1 undodir=. directory=. viewdir=. backupdir=.' @@ -305,7 +310,7 @@ end -- Executes an ex-command by user input. Because nvim_input() is used, VimL -- errors will not manifest as client (lua) errors. Use command() for that. -local function execute(...) +local function feed_command(...) for _, v in ipairs({...}) do if v:sub(1, 1) ~= '/' then -- not a search command, prefix with colon @@ -566,7 +571,7 @@ local M = { insert = insert, iswin = iswin, feed = feed, - execute = execute, + feed_command = feed_command, eval = nvim_eval, call = nvim_call, command = nvim_command, |