Merge "Include IPv6 DNS servers in wifi details" into oc-mr1-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
1b62d99433
@@ -437,10 +437,14 @@ public class WifiDetailPreferenceControllerTest {
|
||||
public void dnsServersPref_shouldHaveDetailTextSet() throws UnknownHostException {
|
||||
mLinkProperties.addDnsServer(InetAddress.getByAddress(new byte[]{8,8,4,4}));
|
||||
mLinkProperties.addDnsServer(InetAddress.getByAddress(new byte[]{8,8,8,8}));
|
||||
mLinkProperties.addDnsServer(Constants.IPV6_DNS);
|
||||
|
||||
displayAndResume();
|
||||
|
||||
verify(mockDnsPref).setDetailText("8.8.4.4\n8.8.8.8");
|
||||
verify(mockDnsPref).setDetailText(
|
||||
"8.8.4.4\n" +
|
||||
"8.8.8.8\n" +
|
||||
Constants.IPV6_DNS.getHostAddress());
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -546,12 +550,14 @@ public class WifiDetailPreferenceControllerTest {
|
||||
|
||||
lp.addDnsServer(Constants.IPV6_DNS);
|
||||
updateLinkProperties(lp);
|
||||
inOrder.verify(mockDnsPref, never()).setVisible(true);
|
||||
inOrder.verify(mockDnsPref).setDetailText(Constants.IPV6_DNS.getHostAddress());
|
||||
inOrder.verify(mockDnsPref).setVisible(true);
|
||||
|
||||
lp.addDnsServer(Constants.IPV4_DNS1);
|
||||
lp.addDnsServer(Constants.IPV4_DNS2);
|
||||
updateLinkProperties(lp);
|
||||
inOrder.verify(mockDnsPref).setDetailText(
|
||||
Constants.IPV6_DNS.getHostAddress() + "\n" +
|
||||
Constants.IPV4_DNS1.getHostAddress() + "\n" +
|
||||
Constants.IPV4_DNS2.getHostAddress());
|
||||
inOrder.verify(mockDnsPref).setVisible(true);
|
||||
|
Reference in New Issue
Block a user