Merge "Improve the wifi description for the case of private DNS broken" am: 37b17ae752 am: 5eda5a3e7f

am: 9b29332cd3

Change-Id: I3cd916c67afaebfd62863301eca5f6aeb8b0d1c5
This commit is contained in:
Lucas Lin
2019-10-23 03:20:15 -07:00
committed by android-build-merger
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*/))