Display App installed in other user in All Apps
Only for admin user. Also clean up unused getInstallationStatus(). Fix: 277299765 Test: Manually with All Apps when multiple users is on Test: Unit test Change-Id: I4de681c101a605e3517dcd8765bf7a95d1b76417
This commit is contained in:
@@ -160,30 +160,6 @@ public class UtilsTest {
|
||||
Utils.maybeInitializeVolume(storageManager, new Bundle());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void getInstallationStatus_notInstalled_shouldReturnUninstalled() {
|
||||
assertThat(Utils.getInstallationStatus(new ApplicationInfo()))
|
||||
.isEqualTo(R.string.not_installed);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void getInstallationStatus_enabled_shouldReturnInstalled() {
|
||||
final ApplicationInfo info = new ApplicationInfo();
|
||||
info.flags = ApplicationInfo.FLAG_INSTALLED;
|
||||
info.enabled = true;
|
||||
|
||||
assertThat(Utils.getInstallationStatus(info)).isEqualTo(R.string.installed);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void getInstallationStatus_disabled_shouldReturnDisabled() {
|
||||
final ApplicationInfo info = new ApplicationInfo();
|
||||
info.flags = ApplicationInfo.FLAG_INSTALLED;
|
||||
info.enabled = false;
|
||||
|
||||
assertThat(Utils.getInstallationStatus(info)).isEqualTo(R.string.disabled);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void isProfileOrDeviceOwner_deviceOwnerApp_returnTrue() {
|
||||
when(mDevicePolicyManager.isDeviceOwnerAppOnAnyUser(PACKAGE_NAME)).thenReturn(true);
|
||||
|
Reference in New Issue
Block a user