diff options
author | kylo252 <[email protected]> | 2022-01-02 14:53:01 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2022-01-02 14:53:01 +0100 |
commit | b3cfd165fbca4c8b595ed577027a5171e33a00e9 (patch) | |
tree | bfc6526edf613b294733d46ff823d69d6e9a58df /tests/minimal_init.lua | |
parent | 73bf039c6333ba9cb3af93437b26c41e14566c47 (diff) |
refactor(test): cleanup test utilities (#2132)
Diffstat (limited to 'tests/minimal_init.lua')
-rw-r--r-- | tests/minimal_init.lua | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/minimal_init.lua b/tests/minimal_init.lua index 126f8e6e..0178514b 100644 --- a/tests/minimal_init.lua +++ b/tests/minimal_init.lua @@ -1,5 +1,12 @@ local path_sep = vim.loop.os_uname().version:match "Windows" and "\\" or "/" +local base_dir = os.getenv "LUNARVIM_RUNTIME_DIR" .. path_sep .. "lvim" +local tests_dir = base_dir .. path_sep .. "tests" -vim.opt.rtp:append(os.getenv "LUNARVIM_RUNTIME_DIR" .. path_sep .. "lvim") +vim.opt.rtp = { base_dir, tests_dir, os.getenv "VIMRUNTIME" } + +vim.opt.swapfile = false + +-- load helper functions before any other plugin to avoid name-collisions +pcall(require, "tests.helpers") require("lvim.bootstrap"):init() |