rust-lang / rust-lang/rust-analyzer
regression in #17105 : debugger test runs get captured output
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 16.9k
- Forks
- 2.2k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 72
Description
17105 made --nocapture a configurable option. This is entirely reasonable for 'Run test', where many tests may be invoked.
For debugging however, the common case is debugging a single test that is failing inscrutably, and now the debugger just shows no output.
and - we can't have the (nice) show-output for 'Run test', and nocapture for 'Debug' because the PR only added a single option.
rust-analyzer version: rust-analyzer version: 0.3.2045-standalone (4afe0d539 2024-07-21) [c:\Users\robertc.vscode\extensions\rust-lang.rust-analyzer-0.3.2045-win32-x64\server\rust-analyzer.exe]
rustc version: rustc 1.79.0 (129f3b996 2024-06-10)
editor or extension: VSCode
relevant settings: (eg. client settings, or environment variables like CARGO, RUSTC, RUSTUP_HOME or CARGO_HOME)
repository link (if public, optional): (eg. rust-analyzer)
code snippet to reproduce:
// add your code here
#[test]
fn invisible() {
eprintln!("where is my output");
1/0 // <- break here.
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing issue #17105 and the test-running paths for “Run test” versus “Debug” in rust-analyzer. Reproduce the example with the debugger and check how --nocapture is selected. Done means Run test retains captured-output behavior while Debugging a single test exposes its output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- devtools, testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100