@Test
  void comparatorReturns0WhenBothHostNamesAreTheSameAndPortIsSame() {
    assertThat(SOCKET_ADDRESS_COMPARATOR.compare(new HostAndPort("locator1", 1234),
        new HostAndPort("locator1", 1234))).isEqualTo(0);
  }
The explicit order of these isn't important, only that it be consistent.
geode-core/src/test/java/org/apache/geode/cache/client/internal/LocatorListTest.java