mirror of
https://github.com/neovim/neovim
synced 2025-07-15 16:51:49 +00:00
docs: api, pack, events, develop
This commit is contained in:
@ -74,23 +74,12 @@ describe('vim.system', function()
|
||||
end)
|
||||
|
||||
it('can set environment', function()
|
||||
eq(
|
||||
'TESTVAL',
|
||||
system(
|
||||
{ n.testprg('printenv-test'), 'TEST' },
|
||||
{ env = { TEST = 'TESTVAL' }, text = true }
|
||||
).stdout
|
||||
)
|
||||
end)
|
||||
local function test_env(opt)
|
||||
eq('TESTVAL', system({ n.testprg('printenv-test'), 'TEST' }, opt).stdout)
|
||||
end
|
||||
|
||||
it('can set environment with clear_env = true', function()
|
||||
eq(
|
||||
'TESTVAL',
|
||||
system(
|
||||
{ n.testprg('printenv-test'), 'TEST' },
|
||||
{ clear_env = true, env = { TEST = 'TESTVAL' }, text = true }
|
||||
).stdout
|
||||
)
|
||||
test_env({ env = { TEST = 'TESTVAL' }, text = true })
|
||||
test_env({ clear_env = true, env = { TEST = 'TESTVAL' }, text = true })
|
||||
end)
|
||||
|
||||
it('can set environment with clear_env = true and env = nil', function()
|
||||
|
@ -5,7 +5,7 @@
|
||||
-- null_spec.lua
|
||||
-- operators_spec.lua
|
||||
--
|
||||
-- Tests for the Vimscript |builtin-functions| library should live in:
|
||||
-- Tests for the Vimscript |vimscript-functions| library should live in:
|
||||
-- test/functional/vimscript/<funcname>_spec.lua
|
||||
-- test/functional/vimscript/functions_spec.lua
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
-- Tests for misc Vimscript |builtin-functions|.
|
||||
-- Tests for misc Vimscript |vimscript-functions|.
|
||||
--
|
||||
-- If a function is non-trivial, consider moving its spec to:
|
||||
-- test/functional/vimscript/<funcname>_spec.lua
|
||||
|
Reference in New Issue
Block a user