Repository navigation
Add dynamic generic-help parity guardrails and skill guidance - #57103
Merged
JeremyKuhne merged 1 commit intoNov 16, 2026
Merged
Conversation
Co-authored-by: Copilot <[email protected]>
|
Azure Pipelines: Successfully started running 2 pipeline(s). 1 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues block approval of the help-parity regression tests and contributor guidance.
No open issues 🎉
What changed in this PR
Adds regression guardrails for the CLI’s optimized top-level help parsing introduced in #56267. The changes expand tests and contributor guidance without changing production CLI behavior.
Changes:
- Discover top-level commands and aliases dynamically for managed and Native AOT help-parity tests.
- Compare managed help metadata and broaden rendered-output parity coverage.
- Document how CLI authors and reviewers should keep minimal help parsing and AOT fallback routing synchronized.
| File | Description |
|---|---|
test/dotnet.Tests/ParserTests/GenericCommandHelpParserTests.cs |
Adds dynamic command/alias coverage, help-metadata checks, and output-parity checks. |
test/dotnet-aot.Tests/AotParserTests.cs |
Expands dynamic coverage and output parity for eligible AOT commands and aliases. |
.github/skills/code-review/SKILL.md |
Adds review guidance for keeping generic-help paths synchronized. |
.github/skills/add-cli-command/SKILL.md |
Documents help fast-path registration and dynamic-help fallback requirements. |
.github/skills/add-cli-command/references/file-map.md |
Maps help-routing implementation points and parity tests. |
Review effort: Balanced
joeloff
approved these changes
Nov 13, 2026
This was referenced Nov 16, 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.
Follow-up to #56267 (comment) to catch missed
TryParseGenericCommandHelp/CreateCommandForGenericHelpupdates when top-level CLI commands, aliases, or help-visible parser configuration change.Summary
dotnet.Tests&dotnet-aot.Tests):TryParseGenericCommandHelpcoverage checks inGenericCommandHelpParserTestsandAotParserTeststo enumerate[command.Name, .. command.Aliases]acrossParser.RootCommand.Subcommandsrather thancommand.Namealone.Parser.RootCommand.Subcommandsinstead of hardcoded per-command[DataRow]lists (including expanding AOT output parity from 4 commands to all eligible non-forwarding commands and aliases).TryParseGenericCommandHelp_PreservesHelpSurfaceMetadataForAllInProcessCommandsto compare visible options, arguments, subcommands, and help-affecting completion sources (HelpNameunset) between the minimal and full trees, catching missed<Name>CommandParser.ConfigureCommandwiring deterministically even without a project fixture or network access.add-cli-command(SKILL.mdandreferences/file-map.md) andcode-review(SKILL.md) to explicitly coverCreateCommandForGenericHelp,TryParseGenericCommandHelp, andAotPrintHelpAction.Validation
dotnet.Tests(GenericCommandHelpParserTests): 48 passed, 0 failed.dotnet-aot.Tests(AotParserTests): 94 passed under both the managed runner and NativeAOT-publisheddotnet-aot.Tests.exe(win-x64)."sln"fromCreateCommandForGenericHelpand omittingReferenceCommandParser.ConfigureCommandfromTryParseGenericCommandHelpboth fail the new dynamic tests immediately.