-
Notifications
You must be signed in to change notification settings - Fork 37
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
RHOAIENG-15772: tests(odh-nbc): write envtest kubeconfig to disk upon request #450
RHOAIENG-15772: tests(odh-nbc): write envtest kubeconfig to disk upon request #450
Conversation
0033fac
to
91ba6ad
Compare
@jiridanek thanks for this /lgtm Maybe you could put some note in the readme or somewhere? Just state that this property exists, what it is for and how it can be utilized. So that anyone can see easily? 🙂 |
@@ -129,6 +130,16 @@ var _ = BeforeSuite(func() { | |||
}) | |||
Expect(err).NotTo(HaveOccurred()) | |||
|
|||
if kubeconfigPath, found := os.LookupEnv("DEBUG_WRITE_KUBECONFIG"); found { |
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.
Maybe you could put some note in the readme or somewhere? Just state that this property exists, what it is for and how it can be utilized. So that anyone can see easily? 🙂
Yeah, good point. Does the env variable name make sense? And should there be a log message about creating/not creating the kubeconfig file?
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.
No problem with the variable name from my side. Also, log message is a good idea - would be nice to print it including the path where this file will be written out.
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.
Added both
… request This helps with debugging because it's then possible to do e.g. ``` KUBECONFIG=/tmp/envtest.kubeconfig k9s ``` and investigate the cluster while the test is paused on a breakpoint.
91ba6ad
to
b642e51
Compare
golangci-lint went crazy after I rebased? |
Okay, the linter failures will be handled by different issue (jira tracker exists already); the failed two unit tests is a known flakyness (also tracked in a jira). Thank you for the update, Jiri. I put two comments, but LGTM otherwise! |
Co-authored-by: Jan Stourac <jstourac@redhat.com>
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: jiridanek 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 |
ed444be
into
opendatahub-io:main
https://issues.redhat.com/browse/RHOAIENG-15772
Description
This helps with debugging because it's then possible to do e.g.
and investigate the cluster while the test is paused on a breakpoint.
How Has This Been Tested?
Works on my macOS laptop.
Merge criteria: