Add unit tests for TrxTestDefinitionName behavior in TrxReportEngine#7598
Merged
Youssef1313 merged 2 commits intodev/ygerges/trx-displayfrom Mar 24, 2026
Merged
Add unit tests for TrxTestDefinitionName behavior in TrxReportEngine#7598Youssef1313 merged 2 commits intodev/ygerges/trx-displayfrom
Youssef1313 merged 2 commits intodev/ygerges/trx-displayfrom
Conversation
Co-authored-by: Youssef1313 <31348972+Youssef1313@users.noreply.github.com> Agent-Logs-Url: https://github.com/microsoft/testfx/sessions/0ea6db2e-9004-49e0-8893-97d2d4447ba8
Copilot
AI
changed the title
[WIP] [WIP] Address feedback on test definition name alignment in TRX files
Add unit tests for TrxTestDefinitionName behavior in TrxReportEngine
Mar 24, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addresses missing test coverage for the
TrxTestDefinitionNameproperty logic introduced to alignUnitTest/@namein TRX files with test case display names rather than test result display names.Tests added
Explicit name used for
UnitTest/@name: WhenTrxTestDefinitionNameis present,UnitTest/@nameuses it whileUnitTestResult/@testNamecontinues to use the node's display name.Duplicate id / conflicting explicit names throws: Two results sharing the same test id but carrying different explicit
TrxTestDefinitionNamevalues →InvalidOperationException.Ordering: fallback-first then matching explicit succeeds: First result has no
TrxTestDefinitionName(falls back to display name); second result provides an explicitTrxTestDefinitionNameequal to that fallback → no exception, dictionary updated to mark the entry as explicitly provided.🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.