diff options
author | dundargoc <gocdundar@gmail.com> | 2024-04-08 11:03:20 +0200 |
---|---|---|
committer | dundargoc <33953936+dundargoc@users.noreply.github.com> | 2024-04-08 22:51:00 +0200 |
commit | 7035125b2b26aa68fcfb7cda39377ac79926a0f9 (patch) | |
tree | d194a3556a367b42505f9e7d26637e7cb3674928 /test/functional/ex_cmds/arg_spec.lua | |
parent | 978962f9a00ce75216d2c36b79397ef3d2b54096 (diff) | |
download | rneovim-7035125b2b26aa68fcfb7cda39377ac79926a0f9.tar.gz rneovim-7035125b2b26aa68fcfb7cda39377ac79926a0f9.tar.bz2 rneovim-7035125b2b26aa68fcfb7cda39377ac79926a0f9.zip |
test: improve test conventions
Work on https://github.com/neovim/neovim/issues/27004.
Diffstat (limited to 'test/functional/ex_cmds/arg_spec.lua')
-rw-r--r-- | test/functional/ex_cmds/arg_spec.lua | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/test/functional/ex_cmds/arg_spec.lua b/test/functional/ex_cmds/arg_spec.lua index 45b2f50af1..3c12c535dd 100644 --- a/test/functional/ex_cmds/arg_spec.lua +++ b/test/functional/ex_cmds/arg_spec.lua @@ -1,8 +1,8 @@ -local helpers = require('test.functional.helpers')(after_each) -local eq, command, fn = helpers.eq, helpers.command, helpers.fn -local ok = helpers.ok -local matches = helpers.matches -local clear = helpers.clear +local t = require('test.functional.testutil')(after_each) +local eq, command, fn = t.eq, t.command, t.fn +local ok = t.ok +local matches = t.matches +local clear = t.clear describe(':argument', function() before_each(function() @@ -11,19 +11,19 @@ describe(':argument', function() it('does not restart :terminal buffer', function() command('terminal') - helpers.feed([[<C-\><C-N>]]) + t.feed([[<C-\><C-N>]]) command('argadd') - helpers.feed([[<C-\><C-N>]]) + t.feed([[<C-\><C-N>]]) local bufname_before = fn.bufname('%') local bufnr_before = fn.bufnr('%') matches('^term://', bufname_before) -- sanity command('argument 1') - helpers.feed([[<C-\><C-N>]]) + t.feed([[<C-\><C-N>]]) local bufname_after = fn.bufname('%') local bufnr_after = fn.bufnr('%') - eq('[' .. bufname_before .. ']', helpers.eval('trim(execute("args"))')) + eq('[' .. bufname_before .. ']', t.eval('trim(execute("args"))')) ok(fn.line('$') > 1) eq(bufname_before, bufname_after) eq(bufnr_before, bufnr_after) |