Skip to content
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

Fixed InvalidUseOfMatchersException in AtomicLongSequenceTest.java #1193

Merged
merged 3 commits into from
Dec 9, 2020

Conversation

KellyShao
Copy link
Contributor

@KellyShao KellyShao commented Nov 29, 2020

Fixed InvalidUseOfMatchersException that caused by method getGeneratedVectorIsNotSupported() in class com.quorum.tessera.eclipselink.AtomicLongSequenceTest.

  • Error msg:

    Misplaced or misused argument matcher detected here:
    -> at  com.quorum.tessera.eclipselink.AtomicLongSequenceTest.getGeneratedVectorIsNotSupported(AtomicLongSequenceTest.java:66)
    -> at com.quorum.tessera.eclipselink.AtomicLongSequenceTest.getGeneratedVectorIsNotSupported(AtomicLongSequenceTest.java:66)
    
  • Root cause:
    It because it's using mockito anyString() & anyInt() while calling the test method, it should be used only for verifying a mock object to ensure a certain method is called with any string parameter inside the test, but not to invoke the test itself.

The InvalidUseOfMatchersException is found by running iDFlakies, after fixing the issue, there's no flaky tests in AtomicLongSequenceTest.java

@CLAassistant
Copy link

CLAassistant commented Nov 29, 2020

CLA assistant check
All committers have signed the CLA.

@codecov-io
Copy link

codecov-io commented Nov 29, 2020

Codecov Report

Merging #1193 (feba809) into master (1fa3edd) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #1193   +/-   ##
=========================================
  Coverage     99.50%   99.50%           
  Complexity     3081     3081           
=========================================
  Files           470      470           
  Lines          9054     9054           
  Branches        480      480           
=========================================
  Hits           9009     9009           
  Misses            5        5           
  Partials         40       40           
Flag Coverage Δ Complexity Δ
unittests 99.50% <ø> (ø) 0.00 <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1fa3edd...feba809. Read the comment docs.

@KellyShao
Copy link
Contributor Author

Hi @chris-j-h
Just out of curiosity, what makes you approved this PR but not merge it?
Please feel free to leave some comments here if this PR needs further improvement. Thanks!

@melowe melowe merged commit 4b5d77b into Consensys:master Dec 9, 2020
@Krish1979 Krish1979 added 21.1.0 cleanup bug Something isn't working labels Jan 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
21.1.0 bug Something isn't working cleanup
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants