-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
.Net: Remove use of Console.SetOut as it impacts other tests #5627
.Net: Remove use of Console.SetOut as it impacts other tests #5627
Conversation
Maybe I'm misunderstanding, but isn't RedirectOutput just a tee that forwards to both stdout and the ITestOutputHelper? If nothing writes to that RedirectOutput, then it's not actually doing anything, and it seems like the purpose of the Console.SetOut was to ensure that Console.Write calls would end up in both places. |
@stephentoub Yes, that is correct. In the tests where I removed the |
Ok |
Motivation and Context
Calls to
Console.SetOut(this._testOutputHelper);
impact tests that are usingConsole
during tear down.Removing these calls as the console output is already being captured in
RedirectOutput
.Description
Contribution Checklist