-
Notifications
You must be signed in to change notification settings - Fork 120
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
Update mockito to v2.10 #2485
Update mockito to v2.10 #2485
Conversation
ci-build |
@@ -171,7 +172,7 @@ public void shouldNotBackupWSWithNonRunningStatus() throws Exception { | |||
// add this verification with timeout to ensure that thread executor had enough time before verification of call | |||
verify(backupManager, timeout(2000)).backupWorkspace(WORKSPACE_ID_1); | |||
verify(backupManager, timeout(2000)).backupWorkspace(WORKSPACE_ID_2); | |||
verify(backupManager, timeout(2000).never()).backupWorkspace("ws3"); |
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.
@benoitf Can you elaborate on why did you change it?
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,
https://static.javadoc.io/org.mockito/mockito-core/1.10.19/org/mockito/verification/VerificationWithTimeout.html
never()
Deprecated.
Validation with timeout combined with never simply does not make sense, as never() will typically immediately pass, and therefore not wait the timeout. The behaviour you may be looking for is actually provided by after().never().
To avoid compilation errors upon upgrade the method is deprecated and it throws a "friendly reminder" exception.
In a future release we will remove timeout(x).atMost(y) and timeout(x).never() from the API.
Do you want to find out more? See issue 235
In 2.x the deprecated stuff has been removed so I switch to after(timeout).never()
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.
tnx for the explanation
test, hello @benoitf |
ci-build |
ci-build |
Change-Id: I98c0e6e8a453e7c82c1edcad5f9ea04b2e714eb5 Signed-off-by: Florent BENOIT <fbenoit@redhat.com>
71c3d80
to
d1657a7
Compare
requires
What does this PR do?
Update mockito to v2.10
it allows to start to use Java9 as runtime
Release Notes
N/A
Docs PR
N/A