Skip to content

Commit

Permalink
fix(neotest): pass opts to neotest
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed May 23, 2023
1 parent cd96e3d commit bf66e71
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lua/lazyvim/plugins/extras/test/core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ return {
},
}, neotest_ns)

local adapters = {}
if opts.adapters then
local adapters = {}
for name, config in pairs(opts.adapters or {}) do
if type(name) == "number" then
adapters[#adapters + 1] = config
Expand All @@ -47,9 +47,10 @@ return {
adapters[#adapters + 1] = adapter
end
end
opts.adapters = adapters
end

require("neotest").setup({ adapters = adapters })
require("neotest").setup(opts)
end,
-- stylua: ignore
keys = {
Expand Down

1 comment on commit bf66e71

@ryansch
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Please sign in to comment.