Interactive display for terminals#3292
Conversation
Evangelink
left a comment
There was a problem hiding this comment.
I need more time but sending my first comments
Co-authored-by: Amaury Levé <amauryleve@microsoft.com>
| _consoleWithProgress = consoleWithProgress; | ||
| } | ||
|
|
||
| public void TestExecutionStarted(DateTimeOffset testStartTime, int workerCount) |
There was a problem hiding this comment.
It's called from only one place with 1 for worker, do we need the parameter? What does it represent?
There was a problem hiding this comment.
This will be used by dotnet test when we have multiple projects running via this same logger, when there is the new protocol between dotnet test and test .exe.
There was a problem hiding this comment.
Is it responsibility of the caller or this class to know how many state object should handle the progress?
There was a problem hiding this comment.
The caller tells us what is the level of parallelism, so we can know how many projects will run at the same time at max, and make UI choices based on that. e.g. we could write: "Starting run in parallel on 10 workers".
Actually managing the states is the responsibility of this console with progress.
Co-authored-by: Amaury Levé <amauryleve@microsoft.com>
| public List<string> Attachments { get; } = new(); | ||
|
|
||
| public List<IProgressMessage> Messages { get; } = new(); |
There was a problem hiding this comment.
Could we expose as "readonly"/"immutable" to avoid having anything that can mutate this?
There was a problem hiding this comment.
It can be done, but it feels like too much ceremony for this simple internal object that just holds the state and is not passed outside of the logger.
Evangelink
left a comment
There was a problem hiding this comment.
We still need to get rid of all the logger wording
…e.cs Co-authored-by: Amaury Levé <amauryleve@microsoft.com>
…tegrationTests/Helpers/AcceptanceAssert.cs Co-authored-by: Amaury Levé <amauryleve@microsoft.com>
Evangelink
left a comment
There was a problem hiding this comment.
Merging as-is. We will do a follow-up for the last few nits






Adds output device that writes tests to ansi or non-ansi terminal, with or without progress indicator.
Features:
A "progress" bar that shows counts of passed, failed and skipped tests. In ANSI mode the progress is updated live on the bottom of the screen, in non-ansi mode the progress is output repeatedly every 3 seconds.
Colored stack traces, with links to files, and (optional) relative paths:
Test run summary:
artifacts report:
Optionally showing passed tests:
Optionally showing link to assembly the test is coming from:
Optional per assembly summary:

Split: