-
Notifications
You must be signed in to change notification settings - Fork 480
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
KeyStoreUtilTest: Remove deprecated ExpectedException.none()
@Rule
& use assertThrows
instead
#1040
Comments
I would like to do that 😊 Hoping to push the PR today |
@dolatapatryk : Thanks a lot. I'm assigning it to you. |
Hi guys, I'm sorry I simply started working on this without asking first since it's a small task. |
@hsteinmueller : ohk, no problem. There are still other places where
@dolatapatryk : Whenever you pick this, Would it be possible for you to remove |
@rohanKanojia yes, of course. I have just submit PR so please don't look at it now. When I changed other places I will notify you :) |
Description
As pointed out in JUnit Javadocs,
ExpectedException.none()
rule is deprecated. We should useAssert.assertThrows
insteadhttps://github.com/eclipse/jkube/blob/ee2390178dcad8a9cc3a9cb6d5e8c5d70a162a04/jkube-kit/build/service/docker/src/test/java/org/eclipse/jkube/kit/build/service/docker/access/KeyStoreUtilTest.java#L33-L34
We need to refactor
loadInvalidPrivateKey
test to useassertThrows
instead. So what is currently this:https://github.com/eclipse/jkube/blob/ee2390178dcad8a9cc3a9cb6d5e8c5d70a162a04/jkube-kit/build/service/docker/src/test/java/org/eclipse/jkube/kit/build/service/docker/access/KeyStoreUtilTest.java#L47-L51
Should be changed to:
Before you start
Make sure you read the contributing guide first. Pay special attention to the ECA agreement section and the requirement to sign-off your commit.
How to manually test my changes
Kubernetes
If you don't have a real Kubernetes cluster available (most probably), you can use Minikube or Kind to test with a local cluster.
OpenShift
If you don't have a real OpenShift cluster available (most probably), you can use Red Hat's developer Sandbox for Red Hat OpenShift. The only requirement is to have a Red Hat account.
Once you have your Sandbox environment, you'll need to download the oc tool from the cluster console.
(Press the
?
icon and from the context menu selectCommand line tools
, you'll be redirected to https://$subdomain.openshiftapps.com/command-lines-tools where you'll be able to download the CLI for your platform)The text was updated successfully, but these errors were encountered: