GEODE-7918: Add assertion message to DNS resolution assertions. (#4859)

* GEODE-7918: Add assertion message to DNS resolution assertions.

In the case of DNS hijacking by an ISP, unresolvable hostnames may be
redirected to a search page. Log this breadcrumb in the test failures.
diff --git a/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/HostAndPortTest.java b/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/HostAndPortTest.java
index dbad906..9625d55 100644
--- a/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/HostAndPortTest.java
+++ b/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/HostAndPortTest.java
@@ -54,7 +54,9 @@
 
     InetSocketAddress actual = locator1.getSocketInetAddress();
 
-    assertThat(actual.isUnresolved()).isTrue();
+    assertThat(actual.isUnresolved())
+        .as("Hostname resolved unexpectedly. Check for DNS hijacking in addition to code errors.")
+        .isTrue();
   }
 
   /**
@@ -143,7 +145,9 @@
         .readObject(new ByteArrayDataInput(out.toByteArray()));
     assertThat(hostAndPort1).isEqualTo(hostAndPort2);
     assertThat(hostAndPort2).isEqualTo(hostAndPort1);
-    assertThat(hostAndPort1.getAddress()).isNull();
+    assertThat(hostAndPort1.getAddress())
+        .as("Hostname resolved unexpectedly. Check for DNS hijacking in addition to code errors.")
+        .isNull();
     assertThat(hostAndPort2.getAddress()).isNull();
     assertThat(hostAndPort2.getSocketInetAddress()).isNotNull();
     assertThat(hostAndPort1.getSocketInetAddress().isUnresolved()).isTrue();
diff --git a/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java b/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java
index 3aa6ee2..6a8f9fc 100644
--- a/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java
+++ b/geode-tcp-server/src/test/java/org/apache/geode/distributed/internal/tcpserver/TcpServerJUnitTest.java
@@ -84,7 +84,9 @@
     @SuppressWarnings("deprecation")
     InfoRequest testInfoRequest = new InfoRequest();
     assertThatThrownBy(() -> tcpClient.requestToServer(new HostAndPort("unknown host name", port),
-        testInfoRequest, TIMEOUT)).isInstanceOf(UnknownHostException.class);
+        testInfoRequest, TIMEOUT))
+            .as("Hostname resolved unexpectedly. Check for DNS hijacking in addition to code errors.")
+            .isInstanceOf(UnknownHostException.class);
   }
 
   @SuppressWarnings("deprecation")