-
Notifications
You must be signed in to change notification settings - Fork 31
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
feat: add env, labels, annotations e2e test #349
Conversation
for k, v := range component.ComponentSpec().PodAnnotations() { | ||
if sts.Spec.Template.Annotations[k] != v { | ||
klog.InfoS("Check Component statefulset annotations but not expected", | ||
"namespace", sts.Namespace, | ||
"name", sts.Name, | ||
"podAnnotations", sts.Spec.Template.Annotations, | ||
) | ||
return false | ||
} | ||
} |
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.
annotationsMatchers := make(map[string]any, len(componentConfigExpected))
for k, v := range component.ComponentSpec().PodAnnotations() {
annotationsMatchers[k] = e2ematcher.ValidatorEq(v)
}
And then put annotationsMatchers in e2ematcher.Struct
above?
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.
I've add a common func MapContainsMatchers
to compare map. #352
2b7931a
to
80a3056
Compare
213f1f5
to
ff9b647
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.
LGTM
What type of PR is this?
What problem(s) does this PR solve?
Issue(s) number:
Description:
How do you solve it?
Special notes for your reviewer, ex. impact of this fix, design document, etc: