🐛 Fix GetAddOnConfigRef selection order#388
Conversation
…he first Generated-by: Cursor (Claude Opus 4.6 High) Signed-off-by: Kevin Cormier <kcormier@redhat.com>
Generated-by: Cursor (Claude Opus 4.6 High) Signed-off-by: Kevin Cormier <kcormier@redhat.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: KevinFCormier The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
WalkthroughGetAddOnConfigRef now scans all matching config references and returns the last match instead of the first. A new table-driven test covers empty, unmatched, single-match, multiple-match, and interleaved-match cases. ChangesConfig reference precedence
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@haoqing0110 or @qiujian16 - this change looks good to me, but could one of you verify? Just want to confirm that this is the intended ordering (rather than the docs being the place that is incorrect). I have the same question when it comes to the ClusterManagementAddOn:
|
Summary
Corrects precedence of selection when there are multiple config references of the same group-kind. (Should be last in list instead of first.)
Related issue(s)
Fixes #387
Summary by CodeRabbit
Bug Fixes
Tests