diff options
author | kylo252 <[email protected]> | 2021-10-09 22:17:30 +0200 |
---|---|---|
committer | kylo252 <[email protected]> | 2021-10-09 22:17:30 +0200 |
commit | caf62bcfed4fc6cfed26164e39d22a568d21f9d0 (patch) | |
tree | 47f7ddcbe7ef10b6cffd8398dbfc215d94fc2fae /tests/bootstrap_spec.lua | |
parent | 4126e5765d69840660fab2a05bbc664ad0117b95 (diff) | |
parent | 82b7a35858479223c1e34bea2f64451ecf1e5f66 (diff) |
Merge remote-tracking branch 'origin/rolling'
Diffstat (limited to 'tests/bootstrap_spec.lua')
-rw-r--r-- | tests/bootstrap_spec.lua | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/tests/bootstrap_spec.lua b/tests/bootstrap_spec.lua new file mode 100644 index 00000000..e5f7244d --- /dev/null +++ b/tests/bootstrap_spec.lua @@ -0,0 +1,28 @@ +local a = require "plenary.async_lib.tests" + +a.describe("initial start", function() + local uv = vim.loop + local home_dir = uv.os_homedir() + local lvim_config_path = get_config_dir() or home_dir .. "/.config/lvim" + local lvim_runtime_path = get_runtime_dir() or home_dir .. "/.local/share/lunarvim" + + a.it("shoud be able to detect test environment", function() + assert.truthy(os.getenv "LVIM_TEST_ENV") + assert.falsy(package.loaded["impatient"]) + end) + + a.it("should not be reading default neovim directories in the home directoies", function() + local rtp_list = vim.opt.rtp:get() + assert.falsy(vim.tbl_contains(rtp_list, vim.fn.stdpath "config")) + end) + + a.it("should be able to read lunarvim directories", function() + local rtp_list = vim.opt.rtp:get() + assert.truthy(vim.tbl_contains(rtp_list, lvim_runtime_path .. "/lvim")) + assert.truthy(vim.tbl_contains(rtp_list, lvim_config_path)) + end) + + a.it("should be able to run treesitter without errors", function() + assert.truthy(vim.treesitter.highlighter.active) + end) +end) |