ROSAENG-65904 | fix: sync structure tests and CI fixes - #3531
Conversation
Remove stale issuer-url entries and add flags from v0.1.9 pathbind regen. Add regression test for unset bool normalization.
Unblocks lint on hyperfleet-v2 after openshift#3510 merge.
Line-length, staticcheck, and unused-code fixes so pre-push checks pass on hyperfleet-v2.
openshift#3510 renamed the hyperfleet URL field from Platform API to V2 API.
Use fmt.Print for template body that already ends with a newline.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository YAML (base), Central YAML (inherited) Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
| "github.com/spf13/cobra" | ||
| ) | ||
|
|
||
| func TestNormalizeClusterCreateInput_clearsUnsetSerializeImagePulls(t *testing.T) { |
There was a problem hiding this comment.
The test proves the normalization mechanism works for *bool fields. Consider extending to a table-driven test over all *bool fields (DeleteProtection, MultiArch) to guard against future codegen regressions.
There was a problem hiding this comment.
Thanks for the comments, just see this now.
There was a problem hiding this comment.
Done in 674aacf — table-driven create/update tests now cover delete-protection, serialize-image-pulls, and multi-arch.
| } | ||
| } | ||
|
|
||
| func TestNormalizeClusterUpdateInput_clearsUnsetSerializeImagePulls(t *testing.T) { |
There was a problem hiding this comment.
Nit: create has both unset-clears and changed-keeps tests; update only has unset-clears. Consider adding the symmetric 'keeps changed' case for update.
There was a problem hiding this comment.
Added TestNormalizeClusterUpdateInput_keepsChangedBoolFlags with the same table-driven pattern as create.
|
/lgtm |
|
/approve |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: Alcamech, cdoan1 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 |
1 similar comment
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: Alcamech, cdoan1 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 |
Cover all *bool flags on create/update and add symmetric keeps-changed cases for update per review feedback.
Clear AWS_REGION from the environment so the no-extractable-region case is not masked when the shell has a region set from e2e runs.
|
New changes are detected. LGTM label has been removed. |
Summary
command_args.ymlwith v0.1.9 pathbind regen (remove staleissuer-url, addplatform/provisioner-config-name/role-arn)cluster_create_normalize_test.goregression test for unset bool normalizationhyperfleet-v2(lint, whoami test label, operatorroles test, network vet)Context
#3510 merged the pathbind v0.1.9 vendor bump and bool normalization fix. Structure tests and a few unit tests were out of sync. #3529 is redundant for the pathbind fix; this PR carries only the remaining follow-up.
Test plan
go test ./cmd/rosa/...go test ./pkg/hyperfleet/pathbind/...make lint