File tree Expand file tree Collapse file tree 3 files changed +26
-3
lines changed Expand file tree Collapse file tree 3 files changed +26
-3
lines changed Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ function M.dap_run(config)
105105 --- @type uv_tcp_t
106106 local server
107107
108- require (' dap' ).run (config , {
108+ require (' dap' ).run (config --[[ @as Configuration ]] , {
109109 before = function (conf )
110110 log .debug (' running before dap callback' )
111111
Original file line number Diff line number Diff line change @@ -4,7 +4,26 @@ local JavaTestClient = require('java-core.ls.clients.java-test-client')
44
55local M = {}
66
7- --- @class JavaTestLauncherConfig
7+ --- @class JavaTestLauncherConfigOverridable : JavaDapConfiguration
8+ --- @field name ? string
9+ --- @field type ? string
10+ --- @field request ? string
11+ --- @field mainClass ? string
12+ --- @field projectName ? string
13+ --- @field cwd ? string
14+ --- @field classPaths ? string[]
15+ --- @field modulePaths ? string[]
16+ --- @field vmArgs ? string
17+ --- @field noDebug ? boolean
18+ --- @field javaExec ? string
19+ --- @field args ? string
20+ --- @field env ? { [string] : string ; }
21+ --- @field envFile ? string
22+ --- @field sourcePaths ? string[]
23+ --- @field preLaunchTask ? string
24+ --- @field postDebugTask ? string
25+
26+ --- @class JavaTestLauncherConfig : JavaDapConfiguration
827--- @field name string
928--- @field type string
1029--- @field request string
Original file line number Diff line number Diff line change 9898
9999--- Run the given test
100100--- @param tests JavaTestFindJavaProjectsResponse
101+ --- @param config ? JavaTestLauncherConfigOverridable config to override the default values in test launcher config
101102--- @return Promise
102- function M :run_test (tests )
103+ function M :run_test (tests , config )
103104 --- @type JavaTestJunitLaunchArguments
104105 local launch_args
105106
@@ -129,6 +130,9 @@ function M:run_test(tests)
129130
130131 log .debug (' dap launcher config is: ' , dap_launcher_config )
131132
133+ dap_launcher_config =
134+ vim .tbl_deep_extend (' force' , dap_launcher_config , config or {})
135+
132136 return JavaDap .dap_run (dap_launcher_config )
133137 end
134138 )
You can’t perform that action at this time.
0 commit comments