Merge "QS work profile network logging test" into sc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
c1b5d9c206
@@ -196,7 +196,7 @@ public class QSSecurityFooterTest extends SysuiTestCase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testNetworkLoggingEnabled() {
|
public void testNetworkLoggingEnabled_deviceOwner() {
|
||||||
when(mSecurityController.isDeviceManaged()).thenReturn(true);
|
when(mSecurityController.isDeviceManaged()).thenReturn(true);
|
||||||
when(mSecurityController.isNetworkLoggingEnabled()).thenReturn(true);
|
when(mSecurityController.isNetworkLoggingEnabled()).thenReturn(true);
|
||||||
mFooter.refreshState();
|
mFooter.refreshState();
|
||||||
@@ -221,6 +221,18 @@ public class QSSecurityFooterTest extends SysuiTestCase {
|
|||||||
mFooterText.getText());
|
mFooterText.getText());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testNetworkLoggingEnabled_managedProfileOwner() {
|
||||||
|
when(mSecurityController.hasWorkProfile()).thenReturn(true);
|
||||||
|
when(mSecurityController.isNetworkLoggingEnabled()).thenReturn(true);
|
||||||
|
mFooter.refreshState();
|
||||||
|
|
||||||
|
TestableLooper.get(this).processAllMessages();
|
||||||
|
assertEquals(mContext.getString(
|
||||||
|
R.string.quick_settings_disclosure_managed_profile_network_activity),
|
||||||
|
mFooterText.getText());
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testManagedCACertsInstalled() {
|
public void testManagedCACertsInstalled() {
|
||||||
when(mSecurityController.isDeviceManaged()).thenReturn(true);
|
when(mSecurityController.isDeviceManaged()).thenReturn(true);
|
||||||
|
|||||||
Reference in New Issue
Block a user