### Question:
HostPort { public static HostPort allAddresses(int port) { return new HostPort(port); } private  HostPort(int port);  HostPort(String host, int port); static boolean isLocalAddress(InetAddress address); static HostPort allAddresses(int port); static HostPort localAddress(int port); static HostPort valueOf(String hostPort); String getHost(); int getPort(); boolean isLocalAddress(); InetSocketAddress toInetSocketAddress(); @Override String toString(); boolean isEquivalentTo(final HostPort other); @Override boolean equals(Object obj); @Override int hashCode(); static final String WILDCARD_ADDRESS; }### Answer:
@Test public void allAddressesEquals() { HostPort hp1 = HostPort.allAddresses(1389); HostPort hp2 = HostPort.allAddresses(1389); assertThat(hp1).isEqualTo(hp2); }