-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
馃尡 Use internal/builders in tests for webhook package #5622
馃尡 Use internal/builders in tests for webhook package #5622
Conversation
@@ -252,7 +252,7 @@ func (webhook *Cluster) validateTopology(ctx context.Context, old, new *clusterv | |||
allErrs = append( | |||
allErrs, field.Invalid( | |||
field.NewPath("spec", "topology", "class"), | |||
new.Name, | |||
new.Spec.Topology.Class, |
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.
This is a small bugfix to use the clusterClass name in this error message.
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.
Great to see builders plugging in in new places 馃コ
one one small nit from my side
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.
Overall looks great! A few nits
ae9e817
to
c3234a6
Compare
lgtm +/- squash |
Signed-off-by: killianmuldoon <kmuldoon@vmware.com>
c3234a6
to
87afe7f
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: fabriziopandini The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/lgtm |
Signed-off-by: killianmuldoon kmuldoon@vmware.com
This updates the unit tests in the webhooks folder to use our test builders instead of raw structs. This will make it easier to create new tests for compatibility and variables in the webhooks package.
Fixes #5621