Closed michaeleisel closed 5 months ago
Hi @michaeleisel , I found the same issue, but fixed it with the following config:
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in executable 'repo/libs/some-app'",
"args": [],
"cwd": "${workspaceFolder}/libs/some-app/",
"cargo": {
"args": [
"test",
"--no-run",
"--manifest-path=${workspaceFolder}/libs/some-app/Cargo.toml",
],
},
}
Let me know if this helps.
Works great, thanks 👍
OS: Ubuntu 22.04 VSCode version: 1.85.1 CodeLLDB version: 1.10.0 Compiler: rust Debuggee: a cargo test run
When I try to run
cargo test
in a debugger for my project, it fails, sayingcould not find Cargo.toml in /path/to/workspaceDirectory
. This is because my project is actually in/path/to/workspaceDirectory/rust
. Here you can see the config I used, with some fruitless attempts at usingcwd
andrelativePathBase
. It'd be great to be able to do this without having to move my Rust project into my large VSCode project's root directory.