-
Notifications
You must be signed in to change notification settings - Fork 203
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
Add new pipeline stage that merges groups #1579
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1579 +/- ##
==========================================
+ Coverage 63.41% 63.42% +0.01%
==========================================
Files 181 182 +1
Lines 11797 11818 +21
==========================================
+ Hits 7481 7496 +15
- Misses 3648 3651 +3
- Partials 668 671 +3
Continue to review full report at Codecov.
|
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.
One question that we need to answer before merging, otherwise good.
9fde653
to
9b7a8b9
Compare
9b7a8b9
to
7939833
Compare
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.
Pretty neat use of TypeWalker!
if !resourceName.PackageReference.Equals(updated.Name().PackageReference) { | ||
// Note: If we ever find this generating colliding names, we might need to introduce a unique suffix. | ||
// For now though it doesn't seem to, so preserving the shorter names as they're clearer. | ||
updated = updated.WithName(astmodel.MakeTypeName(resourceName.PackageReference, updated.Name().Name())) |
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.
Presumably in the case of a collision we'll panic rather than just overwriting?
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.
A collision would be err := result.AddAllowDuplicates(newDef)
above returning an error - meaning we had two types that were named the same but are structurally different. Right now that'd just block the whole pipeline and we'd have to come and add handling to deal with it.
- In the case that group A references group B, we need to pull group B's types into group A. - Fixes Azure#1578
7939833
to
1e00474
Compare
Fixes #1578
What this PR does / why we need it: