Error - java.lang.IllegalArgumentException: Comparison method violates its general contract! #2123
Comments
|
How can i do repeat this test @PriyankaKeer ? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi Team,
Getting below error in Junit testcase for comparator.
Caused by: java.lang.IllegalArgumentException: Comparison method violates its general contract!
at java.util.TimSort.mergeHi(TimSort.java:899)
at java.util.TimSort.mergeAt(TimSort.java:516)
at java.util.TimSort.mergeForceCollapse(TimSort.java:457)
at java.util.TimSort.sort(TimSort.java:254)
at java.util.Arrays.sort(Arrays.java:1438)
at java.util.List.sort(List.java:478)
at java.util.Collections.sort(Collections.java:175)
While using below VM argument, it is working fine - For JDK 1.8.
-Djava.util.Arrays.useLegacyMergeSort=true
But the same is failing in Open JDK 1.8.
Thanks in Advance!
The text was updated successfully, but these errors were encountered: