Analyzer catalog hygiene: retire MSTEST0039 constant and replace unactionable TODOs#8092
Merged
Merged
Conversation
Co-authored-by: Evangelink <11340282+Evangelink@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix analyzer catalog hygiene issues for MSTest rules
Analyzer catalog hygiene: retire MSTEST0039 constant and replace unactionable TODOs
May 11, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR improves hygiene across the MSTest analyzer catalog and a few targeted components by (1) ensuring removed analyzer IDs aren’t accidentally reused and (2) converting empty/vague TODOs into actionable, issue-tracked follow-ups (Issue #8086).
Changes:
- Commented out the removed
MSTEST0039diagnostic ID constant (UseNewerAssertThrowsRuleId) to match the established “do not reuse this ID” convention. - Replaced empty TODO placeholders with specific, issue-tracked explanatory comments (notably in console output and TRX process lifetime handling).
- Added Issue #8086 tracking context to several existing TODOs in platform, adapter, and unit test code.
Show a summary per file
| File | Description |
|---|---|
| test/UnitTests/MSTestAdapter.PlatformServices.UnitTests/Services/TestDeploymentTests.cs | Annotates a TODO with Issue #8086 so the flaky/non-mocked deployment test follow-up is trackable. |
| test/UnitTests/MSTestAdapter.PlatformServices.UnitTests/Execution/TestMethodRunnerTests.cs | Adds Issue #8086 tracking to an existing TODO about exception type refinement. |
| src/Platform/Microsoft.Testing.Platform/TestHostControllers/ITestHostProcessInformation.cs | Adds Issue #8086 tracking to an API follow-up TODO (rename/obsolete plan). |
| src/Platform/Microsoft.Testing.Platform/OutputDevice/SimplifiedConsoleOutputDeviceBase.cs | Replaces empty TODOs with concrete, issue-tracked notes about ignored/surfacing file artifacts. |
| src/Platform/Microsoft.Testing.Platform/Hosts/CommonTestHost.cs | Adds Issue #8086 tracking to an existing TODO about reachability/disable sequencing. |
| src/Platform/Microsoft.Testing.Platform/CommandLine/CommandLineHandler.cs | Adds Issue #8086 tracking to TODOs about abstracting Assembly and RuntimeInformation. |
| src/Platform/Microsoft.Testing.Extensions.TrxReport/TrxProcessLifetimeHandler.cs | Replaces an empty TODO with an issue-tracked explanation of the TRX/exit-code mismatch scenario. |
| src/Analyzers/MSTest.Analyzers/Helpers/DiagnosticIds.cs | Comments out MSTEST0039 constant to align with removed-rule ID lifecycle handling. |
| src/Adapter/MSTestAdapter.PlatformServices/Services/TestDataSource.cs | Adds Issue #8086 tracking to an exception-type TODO in the data source error path. |
Copilot's findings
- Files reviewed: 9/9 changed files
- Comments generated: 0
Evangelink
added a commit
that referenced
this pull request
May 12, 2026
…tionable TODOs (#8092) Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Evangelink <11340282+Evangelink@users.noreply.github.com>
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.
Bug Fix
The analyzer catalog had an inconsistency where removed rule
MSTEST0039was still exposed as an active constant, and several TODOs in high-churn areas were empty or too vague to act on. This change aligns rule-ID lifecycle handling and converts unactionable TODOs into explicit, tracked follow-ups.Analyzer ID catalog hygiene
UseNewerAssertThrowsRuleId(MSTEST0039) inDiagnosticIds.csusing the same non-reuse convention as other removed rules.TODO triage in targeted components
SimplifiedConsoleOutputDeviceBase.csTrxProcessLifetimeHandler.cs#8086) to vague TODOs in:CommandLineHandler.csCommonTestHost.csITestHostProcessInformation.csTestDataSource.csTestDeploymentTests.csTestMethodRunnerTests.csAnalyzer release catalog check
USagetypos inAnalyzerReleases.Shipped.mdwere already corrected in the current branch (Usage), so no additional edit was needed there.