Device management info: Refer to current user, not primary user

The device management info page should show information about the
current user's policies, not the primary user's.

Bug: 32692748
Test: m RunSettingsRoboTests

Change-Id: I5d8afa7fae1c0f3a4da78b085365882827e6721b
This commit is contained in:
Bartosz Fabianowski
2017-03-30 10:33:28 +02:00
parent 2b37b43821
commit b836da263d
20 changed files with 89 additions and 139 deletions

View File

@@ -190,7 +190,7 @@ public final class ApplicationFeatureProviderImplTest {
}
private void setUpUsersAndInstalledApps() {
when(mUserManager.getUsers(true)).thenReturn(Arrays.asList(
when(mUserManager.getProfiles(UserHandle.myUserId())).thenReturn(Arrays.asList(
new UserInfo(MAIN_USER_ID, "main", UserInfo.FLAG_ADMIN),
new UserInfo(MANAGED_PROFILE_ID, "managed profile", 0)));