public static boolean isIpV6Endpoint(NetworkEndpoint networkEndpoint) {
    return hasIpAddress(networkEndpoint)
        && networkEndpoint.getIpAddress().getAddressFamily().equals(AddressFamily.IPV6);
  }
@Test
  public void isIpV6Endpoint_withIpV6Endpoint_returnsFalse() {
    NetworkEndpoint ipV6Endpoint =
        NetworkEndpoint.newBuilder()
            .setType(NetworkEndpoint.Type.IP)
            .setIpAddress(
                IpAddress.newBuilder().setAddress("3ffe::1").setAddressFamily(AddressFamily.IPV6))
            .build();
    assertThat(NetworkEndpointUtils.isIpV6Endpoint(ipV6Endpoint)).isTrue();
  }