diff options
Diffstat (limited to 'test/functional')
-rw-r--r-- | test/functional/api/vim_spec.lua | 2 | ||||
-rw-r--r-- | test/functional/provider/nodejs_spec.lua | 12 | ||||
-rw-r--r-- | test/functional/terminal/tui_spec.lua | 13 |
3 files changed, 19 insertions, 8 deletions
diff --git a/test/functional/api/vim_spec.lua b/test/functional/api/vim_spec.lua index 1e910b6aa7..3a686c84e7 100644 --- a/test/functional/api/vim_spec.lua +++ b/test/functional/api/vim_spec.lua @@ -1226,6 +1226,7 @@ describe('api', function() screen:attach() local expected = { { + chan = 1, ext_cmdline = false, ext_popupmenu = false, ext_tabline = false, @@ -1242,6 +1243,7 @@ describe('api', function() screen:attach({ rgb = false }) expected = { { + chan = 1, ext_cmdline = false, ext_popupmenu = false, ext_tabline = false, diff --git a/test/functional/provider/nodejs_spec.lua b/test/functional/provider/nodejs_spec.lua index f69c3e7c78..07a00f8a8c 100644 --- a/test/functional/provider/nodejs_spec.lua +++ b/test/functional/provider/nodejs_spec.lua @@ -16,7 +16,6 @@ end before_each(function() clear() - command([[let $NODE_PATH = get(split(system('npm root -g'), "\n"), 0, '')]]) end) describe('nodejs host', function() @@ -28,21 +27,18 @@ describe('nodejs host', function() it('works', function() local fname = 'Xtest-nodejs-hello.js' write_file(fname, [[ - const socket = process.env.NVIM_LISTEN_ADDRESS; const neovim = require('neovim'); - const nvim = neovim.attach({socket: socket}); + const nvim = neovim.attach({socket: process.env.NVIM_LISTEN_ADDRESS}); nvim.command('let g:job_out = "hello"'); - nvim.command('call jobstop(g:job_id)'); ]]) command('let g:job_id = jobstart(["node", "'..fname..'"])') - retry(nil, 2000, function() eq('hello', eval('g:job_out')) end) + retry(nil, 3000, function() eq('hello', eval('g:job_out')) end) end) it('plugin works', function() local fname = 'Xtest-nodejs-hello-plugin.js' write_file(fname, [[ - const socket = process.env.NVIM_LISTEN_ADDRESS; const neovim = require('neovim'); - const nvim = neovim.attach({socket: socket}); + const nvim = neovim.attach({socket: process.env.NVIM_LISTEN_ADDRESS}); class TestPlugin { hello() { @@ -54,6 +50,6 @@ describe('nodejs host', function() plugin.instance.hello(); ]]) command('let g:job_id = jobstart(["node", "'..fname..'"])') - retry(nil, 2000, function() eq('hello-plugin', eval('g:job_out')) end) + retry(nil, 3000, function() eq('hello-plugin', eval('g:job_out')) end) end) end) diff --git a/test/functional/terminal/tui_spec.lua b/test/functional/terminal/tui_spec.lua index 0ae5802a01..5603224975 100644 --- a/test/functional/terminal/tui_spec.lua +++ b/test/functional/terminal/tui_spec.lua @@ -253,6 +253,19 @@ describe('tui', function() {4:-- TERMINAL --} | ]]) end) + + it('shows up in nvim_list_uis', function() + feed_data(':echo map(nvim_list_uis(), {k,v -> sort(items(v))})\013') + screen:expect([=[ + {5: }| + [[['ext_cmdline', v:false], ['ext_popupmenu', v:fa| + lse], ['ext_tabline', v:false], ['ext_wildmenu', v| + :false], ['height', 6], ['rgb', v:false], ['width'| + , 50]]] | + {10:Press ENTER or type command to continue}{1: } | + {3:-- TERMINAL --} | + ]=]) + end) end) describe('tui with non-tty file descriptors', function() |