Reputation: 8168
I found a solution for JUnit but couldn't find for TestNG.
Upvotes: 1
Views: 2641
Reputation: 26522
There is no equivalent as good as found in the Hamcrest library but you could transform each of the lists to an array and the use:
public static void assertEqualsNoOrder(Object[] actual,
Object[] expected)
as per javadoc:
Asserts that two arrays contain the same elements in no particular order
Upvotes: 6