Skip to content

Conversation

@nohwnd
Copy link
Member

@nohwnd nohwnd commented Dec 1, 2025

Description

Running tests with dotnet test, users see inconsistent number of projects and tests reported in the view. This is a UI only issue, failing tests will still fail the build. It is still worth fixing the issue because it makes the runs show repeatable numbers of tests to the user.

The terminal node can be null before we receive the finish message. This will cause that some summaries are not accounted for and will be missing in the final output.

The node is null for this reason: #12819 That fix is not backported.

Customer Impact: Multiple runs of the same test suite report different total counts of tests and projects.

Regression? No, this was never working correctly since the beginning of test reporting in Terminal Logger.

Risk: Low, it impacts UI only.

Link the PR to the original issue and to the PR to main.
PR to main is merged: #12801
Fixes microsoft/vstest#15307

No additional impact on packages or localization.

Copilot AI review requested due to automatic review settings December 1, 2025 16:04
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a UI issue in the Terminal Logger where test summaries were inconsistently reported due to null node references. The fix ensures that test finish messages (which contain summary statistics) are always processed, even when the terminal node status is null.

Key changes:

  • Modified null-check pattern to allow TLTESTFINISH messages to be processed regardless of node status
  • Added explicit null checks for TLTESTPASSED and TLTESTSKIPPED cases that actually use the node variable

@nohwnd nohwnd requested a review from a team as a code owner December 2, 2025 15:55
@rbhanda rbhanda modified the milestones: .NET 9.0, 9.0.12 Dec 3, 2025
@nohwnd
Copy link
Member Author

nohwnd commented Dec 4, 2025

@JanProvaznik was approved, please merge.

@ViktorHofer ViktorHofer merged commit 3393a8a into dotnet:vs17.14 Dec 4, 2025
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants