aboutsummaryrefslogtreecommitdiff
path: root/test/functional/legacy/074_global_var_in_viminfo_spec.lua
diff options
context:
space:
mode:
authorZyX <kp-pav@yandex.ru>2017-12-03 16:49:30 +0300
committerZyX <kp-pav@yandex.ru>2017-12-03 16:49:30 +0300
commitc49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57 (patch)
treeb7e59c416d1435725c65f8952b6e55c70544d97e /test/functional/legacy/074_global_var_in_viminfo_spec.lua
parent62108c3b0be46936c83f6d4c98b44ceb5e6f77fd (diff)
parent27a577586eace687c47e7398845178208cae524a (diff)
downloadrneovim-c49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57.tar.gz
rneovim-c49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57.tar.bz2
rneovim-c49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57.zip
Merge branch 'master' into s-dash-stdin
Diffstat (limited to 'test/functional/legacy/074_global_var_in_viminfo_spec.lua')
-rw-r--r--test/functional/legacy/074_global_var_in_viminfo_spec.lua30
1 files changed, 14 insertions, 16 deletions
diff --git a/test/functional/legacy/074_global_var_in_viminfo_spec.lua b/test/functional/legacy/074_global_var_in_viminfo_spec.lua
index e8292db8c1..e17b463e30 100644
--- a/test/functional/legacy/074_global_var_in_viminfo_spec.lua
+++ b/test/functional/legacy/074_global_var_in_viminfo_spec.lua
@@ -2,8 +2,8 @@
local helpers = require('test.functional.helpers')(after_each)
local lfs = require('lfs')
-local clear, execute, eq, neq, eval, wait, spawn =
- helpers.clear, helpers.execute, helpers.eq, helpers.neq, helpers.eval,
+local clear, command, eq, neq, eval, wait, spawn =
+ helpers.clear, helpers.command, helpers.eq, helpers.neq, helpers.eval,
helpers.wait, helpers.spawn
describe('storing global variables in ShaDa files', function()
@@ -26,31 +26,29 @@ describe('storing global variables in ShaDa files', function()
71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88,
89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100}
- execute(
- -- This will cause a few errors, do it silently.
- 'set visualbell',
- 'set shada+=!',
- "let MY_GLOBAL_DICT={'foo': 1, 'bar': 0, 'longvarible': 1000}",
- -- Store a really long list. Initially this was testing line wrapping in
- -- viminfo, but shada files has no line wrapping, no matter how long the
- -- list is.
- 'let MY_GLOBAL_LIST=range(1,100)'
- )
+ command('set visualbell')
+ command('set shada+=!')
+ command('let MY_GLOBAL_DICT={\'foo\': 1, \'bar\': 0, \'longvarible\': 1000}')
+ -- Store a really long list. Initially this was testing line wrapping in
+ -- viminfo, but shada files has no line wrapping, no matter how long the
+ -- list is.
+ command('let MY_GLOBAL_LIST=range(1, 100)')
+
eq(test_dict, eval('MY_GLOBAL_DICT'))
eq(test_list, eval('MY_GLOBAL_LIST'))
- execute('wsh! ' .. tempname)
+ command('wsh! ' .. tempname)
wait()
-- Assert that the shada file exists.
neq(nil, lfs.attributes(tempname))
- execute('unlet MY_GLOBAL_DICT',
- 'unlet MY_GLOBAL_LIST')
+ command('unlet MY_GLOBAL_DICT')
+ command('unlet MY_GLOBAL_LIST')
-- Assert that the variables where deleted.
eq(0, eval('exists("MY_GLOBAL_DICT")'))
eq(0, eval('exists("MY_GLOBAL_LIST")'))
- execute('rsh! ' .. tempname)
+ command('rsh! ' .. tempname)
eq(test_list, eval('MY_GLOBAL_LIST'))
eq(test_dict, eval('MY_GLOBAL_DICT'))