Merge "Improve the wifi description for the case of private DNS broken"

This commit is contained in:
Lucas Lin
2019-10-23 09:20:09 +00:00
committed by Gerrit Code Review
2 changed files with 26 additions and 4 deletions

View File

@@ -993,6 +993,14 @@ public class WifiDetailPreferenceControllerTest {
updateNetworkCapabilities(nc);
inOrder.verify(mockHeaderController).setSummary(summary);
// UI will be refreshed when private DNS is broken.
summary = "Private DNS server cannot be accessed";
when(mockAccessPoint.getSettingsSummary(true /* convertSavedAsDisconnected */))
.thenReturn(summary);
nc.setPrivateDnsBroken(true);
updateNetworkCapabilities(nc);
inOrder.verify(mockHeaderController).setSummary(summary);
// UI will be refreshed when device connects to a partial connectivity network.
summary = "Limited connection";
when(mockAccessPoint.getSettingsSummary(true /*convertSavedAsDisconnected*/))