File tree Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Expand file tree Collapse file tree 1 file changed +5
-10
lines changed Original file line number Diff line number Diff line change 1
1
local env = require (" tests.env" )
2
2
local M = {}
3
- _G .attach_debugger = false
3
+
4
+ if not _G .attach_debugger then
5
+ _G .attach_debugger = false
6
+ end
4
7
5
8
--- @param test_name string
6
9
function M .new_child_neovim (test_name )
7
10
--- @class MiniTest.child
8
11
local child = MiniTest .new_child_neovim ()
9
12
local logfile = string.format (" ./tests/logs/%s.log" , test_name )
10
-
11
- -- TODO: this needs a reset, as it is reused in multiple tests
12
- -- TODO: this does not work, as the child needs a string representation of the config
13
13
child .config = nil
14
14
15
15
if vim .fn .filereadable (logfile ) == 1 then
@@ -53,12 +53,7 @@ function M.new_child_neovim(test_name)
53
53
end
54
54
55
55
child .lua ([[
56
- local osv = require("osv")
57
- local debugger_attached = false
58
- osv.on_attach = function() debugger_attached = true end
59
- osv.launch({ port = 8086 })
60
- -- wait until a debuggee is attached, or 30 seconds
61
- vim.wait(30000, function() return debugger_attached end, 10)
56
+ require("osv").launch({ port = 8086, blocking = true })
62
57
]] )
63
58
end
64
59
You can’t perform that action at this time.
0 commit comments