Merge "Merge "Added assertion message to testDns failures" into lollipop-mr1-cts-dev am: 350b2aa" into marshmallow-cts-dev am: 936375b am: 2bfd0e1 am: 2a0f366 am: 39cb9a5 am: 7cde9a8 am: 6d3841c

am: 6ed611d

* commit '6ed611d7823d22330b539761cd3d844a0bd577fd':
  Added assertion message to testDns failures

Change-Id: Ib27f42e21d52aadaf415ac37b10f7ccaf246a261
This commit is contained in:
Owain Davies
2016-04-25 23:55:03 +00:00
committed by android-build-merger

View File

@@ -62,7 +62,8 @@ public class DnsTest extends AndroidTestCase {
try {
addrs = InetAddress.getAllByName("www.google.com");
} catch (UnknownHostException e) {}
assertTrue(addrs.length != 0);
assertTrue("[RERUN] DNS could not resolve www.gooogle.com. Check internet connection",
addrs.length != 0);
boolean foundV4 = false, foundV6 = false;
for (InetAddress addr : addrs) {
if (addr instanceof Inet4Address) foundV4 = true;