whois icon indicating copy to clipboard operation
whois copied to clipboard

Fix flaky test RdapObjectMapperTest#domain

Open hsiangawang opened this issue 4 years ago • 0 comments

The test net.ripe.db.whois.api.rdap.RdapObjectMapperTest#domain compares the result of getNameservers().get(index).getLdhName() to a hard-coded string based on a specific order of entries from keySet used at RdapObjectMapper:422. However, this method does not guarantee that order, and the assertion can fail if the order differs.

The PR uses Matchers.containsInAnyOrder to avoid failures if the order differs.

hsiangawang avatar Nov 16 '20 16:11 hsiangawang