-
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’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cleanup test certificate temp files #9707
Conversation
Signed-off-by: Federico Valeri <[email protected]>
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.
Why not just mark the files as deleteOnExit()
?
Signed-off-by: Federico Valeri <[email protected]>
You are right, that's better. Thanks. I would like to keep the ClientAndServer wrapping in MockCruiseControl, which is useful to isolate test classes from the mockserver dependency. Wdyt? |
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'm fine with the MockCruiseControl change. But maybe it is worth mentioning in the PR description? Also, I wonder if one of the tests has some more places to check. But LGTM otherwise. Thanks.
...r-operator/src/test/java/io/strimzi/operator/cluster/operator/assembly/CaReconcilerTest.java
Show resolved
Hide resolved
Signed-off-by: Federico Valeri <[email protected]>
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. Thanks.
Some tests leave a bunch of temporary files in the /tmp folder, which are used for certificate generation. This change adds code to clean them up after the test has finished. It also hides ClientAndServer in MockCruiseControl to isolate test classes from the mockserver dependency.