Merge "Merge "Added assertion message to testDns failures" into lollipop-mr1-cts-dev am: 350b2aa" into marshmallow-cts-dev

am: 936375b

* commit '936375b6f25a328a06d5b783f6fde63afb13d681':
  Added assertion message to testDns failures

Change-Id: I9a56dfe2d0960898b61f26ccee3607c7558034de
This commit is contained in:
Owain Davies
2016-04-23 06:13:44 +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;