-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #14425 - ShashiSugrim:shashi/issue14403, r=epage
fix: doctest respects Cargo's color options ### What does this PR try to resolve? Explain the motivation behind this change. This commit fixes the issue where cargo's test command doesn't respect the color parameter when it gets passed in like this command: `cargo t --color never --doc -- --color never` Fixes #14403 ### How should we test and review this PR? Test on a basic rust project, with a file called lib.rs that looks like this ``` /// ``` /// bar /// ``` pub fn foo() {} #[cfg(test)] mod tests { #[test] fn foo() { bar } } ``` You can try to replicate the same commands `@zacknewman` used in the description of this issue. `cargo t --color never --doc -- --color never` You will see that compared to the official build of cargo, this build will respect the --color argument
- Loading branch information
Showing
4 changed files
with
13 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters