-
Couldn't load subscription status.
- Fork 5.1k
Rename Etag to ETag in management plane generator #53393
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Co-authored-by: live1206 <[email protected]>
...ges/http-client-csharp-mgmt/generator/Azure.Generator.Management/src/Visitors/NameVisitor.cs
Outdated
Show resolved
Hide resolved
Co-authored-by: live1206 <[email protected]>
There was a problem hiding this 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 renames Etag properties to ETag in the management plane generator to follow proper capitalization conventions. The implementation uses a dictionary-based approach for extensibility, allowing future property name transformations to be easily added.
Key Changes:
- Introduced
_propertyNameRenamingMapdictionary to centralize property name transformations - Added
DoPreVisitPropertyNameRenamingmethod to handle property renaming using dictionary lookups - Added unit test to verify the Etag → ETag transformation
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| eng/packages/http-client-csharp-mgmt/generator/Azure.Generator.Management/src/Visitors/NameVisitor.cs | Added dictionary-based property renaming infrastructure and method to transform Etag to ETag |
| eng/packages/http-client-csharp-mgmt/generator/Azure.Generator.Management/test/NameVisitorTests.cs | Added test case to verify Etag property is renamed to ETag |
...ges/http-client-csharp-mgmt/generator/Azure.Generator.Management/src/Visitors/NameVisitor.cs
Outdated
Show resolved
Hide resolved
...ges/http-client-csharp-mgmt/generator/Azure.Generator.Management/src/Visitors/NameVisitor.cs
Outdated
Show resolved
Hide resolved
Co-authored-by: live1206 <[email protected]>
|
/check-enforcer override |
Rename Etag to ETag in management plane generator
Etagproperties toETagin DoPreVisitProperty methodsSummary of changes:
_propertyNameRenamingMapdictionary to hold property name renaming mappings (currently mapping "Etag" -> "ETag")DoPreVisitPropertyForEtagPropertyNametoDoPreVisitPropertyNameRenamingfor generic extensibilityTestTransformEtagToETagto verify the renaming behaviorOriginal prompt
Fixes #53392
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.