meta: Allow cargo's tests to be run in-process for debugging #9757
Labels
A-testing-cargo-itself
Area: cargo's tests
C-feature-request
Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`
Almost all the cargo tests test cargo as an external process which is great from a purity standpoint.
Unfortunatly llvm doesn't support debugging child processes ( vadimcn/codelldb#317 ), so it's not possible to use an llvm debugger to debug into cargo from a failing test.
It would be really helpful if in cargo-test-support rather than starting a new process there was a flag (maybe an env var set?) to tell it to call the main function directly from the test instead of routing it through a new process. I'm sure all tests won't magically run clean that way, but if the majority do that would be very helpful. I'm sure it's not quite that easy, but being able to debug into cargo from most failing tests would likely reduce the bar to contributing to cargo.
The text was updated successfully, but these errors were encountered: