File tree Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Original file line number Diff line number Diff line change @@ -508,11 +508,21 @@ M.toggle_setting = function(setting)
508
508
end
509
509
510
510
M .select_test_suite = function ()
511
- test_explorer .dap_select_test_suite ()
511
+ local config = conf .get_config_cache ()
512
+ if config and config .settings .metals .testUserInterface == " Test Explorer" then
513
+ test_explorer .dap_select_test_suite ()
514
+ else
515
+ log .error_and_show (messages .enable_test_explorer )
516
+ end
512
517
end
513
518
514
519
M .select_test_case = function ()
515
- test_explorer .dap_select_test_case ()
520
+ local config = conf .get_config_cache ()
521
+ if config and config .settings .metals .testUserInterface == " Test Explorer" then
522
+ test_explorer .dap_select_test_case ()
523
+ else
524
+ log .error_and_show (messages .enable_test_explorer )
525
+ end
516
526
end
517
527
518
528
M .open_new_github_issue = function ()
Original file line number Diff line number Diff line change @@ -63,4 +63,7 @@ You recieved a null response for the tree view.
63
63
If you're using Scala 3, this is expected as it's not support yet.
64
64
If you're using Scala 2, please create an issue for this in nvim-metals.]]
65
65
66
+ M .enable_test_explorer = [[
67
+ You can't use this command unless you have "Test Explorer" set as the value of testUserInterface in your config.
68
+ You can read more about this in :h metals-nvim-dap.]]
66
69
return M
You can’t perform that action at this time.
0 commit comments