aboutsummaryrefslogtreecommitdiff
path: root/test/functional/legacy/012_directory_spec.lua
diff options
context:
space:
mode:
authorbfredl <bjorn.linse@gmail.com>2023-05-21 20:16:05 +0200
committerGitHub <noreply@github.com>2023-05-21 20:16:05 +0200
commit384a3bc308c95c9511eff1b85cd55357bdaedd9e (patch)
tree4ec9a0ae9095af1dbacade1e10e53a3f4d842417 /test/functional/legacy/012_directory_spec.lua
parentedf9a897f089191f2b43985f7ebc11a0b540bb44 (diff)
parent1fe1bb084d0099fc4f9bfdc11189485d0f74b75a (diff)
downloadrneovim-384a3bc308c95c9511eff1b85cd55357bdaedd9e.tar.gz
rneovim-384a3bc308c95c9511eff1b85cd55357bdaedd9e.tar.bz2
rneovim-384a3bc308c95c9511eff1b85cd55357bdaedd9e.zip
Merge pull request #23670 from famiu/refactor/deprecate_opt_api
refactor(options): deprecate nvim[_buf|_win]_[gs]et_option
Diffstat (limited to 'test/functional/legacy/012_directory_spec.lua')
-rw-r--r--test/functional/legacy/012_directory_spec.lua13
1 files changed, 6 insertions, 7 deletions
diff --git a/test/functional/legacy/012_directory_spec.lua b/test/functional/legacy/012_directory_spec.lua
index 050e3855fe..f44ba10f7f 100644
--- a/test/functional/legacy/012_directory_spec.lua
+++ b/test/functional/legacy/012_directory_spec.lua
@@ -15,7 +15,6 @@ local clear = helpers.clear
local insert = helpers.insert
local command = helpers.command
local write_file = helpers.write_file
-local curbufmeths = helpers.curbufmeths
local expect_exit = helpers.expect_exit
local mkdir = helpers.mkdir
@@ -58,9 +57,9 @@ describe("'directory' option", function()
line 3 Abcdefghij
end of testfile]])
- meths.set_option('swapfile', true)
- curbufmeths.set_option('swapfile', true)
- meths.set_option('directory', '.')
+ meths.set_option_value('swapfile', true, {})
+ meths.set_option_value('swapfile', true, {buf=0})
+ meths.set_option_value('directory', '.', {})
-- sanity check: files should not exist yet.
eq(nil, luv.fs_stat('.Xtest1.swp'))
@@ -72,7 +71,7 @@ describe("'directory' option", function()
-- reading the output from :!ls.
neq(nil, luv.fs_stat('.Xtest1.swp'))
- meths.set_option('directory', './Xtest2,.')
+ meths.set_option_value('directory', './Xtest2,.', {})
command('edit Xtest1')
poke_eventloop()
@@ -81,10 +80,10 @@ describe("'directory' option", function()
eq({ "Xtest1.swp", "Xtest3" }, ls_dir_sorted("Xtest2"))
- meths.set_option('directory', 'Xtest.je')
+ meths.set_option_value('directory', 'Xtest.je', {})
command('bdelete')
command('edit Xtest2/Xtest3')
- eq(true, curbufmeths.get_option('swapfile'))
+ eq(true, meths.get_option_value('swapfile', {buf=0}))
poke_eventloop()
eq({ "Xtest3" }, ls_dir_sorted("Xtest2"))