-
Notifications
You must be signed in to change notification settings - Fork 1.8k
test/: clean up some e2e setup code #4315
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
Conversation
|
||
By("cleaning up permissions") | ||
_, _ = tc.Kubectl.Command("delete", "clusterrolebinding", | ||
metricsClusterRoleBindingName) |
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.
the reason. for the break in the lines is for not be required to scroll to check the code.
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 think these lines I changed should still be < 120 chars wide.
|
||
By("deploying project on the cluster") | ||
err := tc.Make("deploy", "IMG="+tc.ImageName) | ||
Expect(err).NotTo(HaveOccurred()) | ||
Expect(tc.Make("deploy", "IMG="+tc.ImageName)).To(Succeed()) |
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.
👍
// WrapWarn is a one-liner to wrap an error from a command that returns (error) in a warning. | ||
func WrapWarn(err error) { | ||
WrapWarnOutput("", err) | ||
} |
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.
WDYT. about push it to upstream?
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.
Sure!
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 added a few comments.
However, I am ok with it. I do not think that the test should fail because any flake faced to cleanup the env as well. 👍
/lgtm
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
Signed-off-by: reinvantveer <[email protected]>
Signed-off-by: rearl <[email protected]>
Description of the change: clean up some e2e setup code
Motivation for the change: fix some potential panics and warn on error instead of not checking error at all
Checklist
If the pull request includes user-facing changes, extra documentation is required:
changelog/fragments
(seechangelog/fragments/00-template.yaml
)website/content/en/docs