pub fn configure_handle_inheritance(
    no_capture: bool
) -> Result<(), ConfigureHandleInheritanceError>
Expand description

Configures stdout, stdin and stderr inheritance by test processes on Windows.

With Rust on Windows, these handles can be held open by tests (and therefore by grandchild processes) even if we run the tests with Stdio::inherit. This can cause problems with leaky tests.

This changes global state on the Win32 side, so the application must manage mutual exclusion around it. Call this right before TestRunner::try_execute.

This is a no-op on non-Windows platforms.

See this issue on the Rust repository for more discussion.