Searched refs:mockUserManager (Results 1 – 6 of 6) sorted by relevance
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/task/ |
D | DisallowAddUserTaskTest.java | 46 @Mock private UserManager mockUserManager; field in DisallowAddUserTaskTest 66 when(mockContext.getSystemService(Context.USER_SERVICE)).thenReturn(mockUserManager); in setUp() 68 when(mockUserManager.hasUserRestriction(anyString(), any(UserHandle.class))) in setUp() 76 when(mockUserManager.getUsers()).thenReturn(Collections.singletonList(primaryUser)); in testMaybeDisallowAddUsers_normalSystem() 85 verify(mockUserManager).setUserRestriction(UserManager.DISALLOW_ADD_USER, true, in testMaybeDisallowAddUsers_normalSystem() 94 when(mockUserManager.getUsers()).thenReturn(Collections.singletonList(primaryUser)); in testMaybeDisallowAddUsers_normalSystem_restrictionAlreadySetupForOneUser() 100 when(mockUserManager.hasUserRestriction(UserManager.DISALLOW_ADD_USER, in testMaybeDisallowAddUsers_normalSystem_restrictionAlreadySetupForOneUser() 108 verify(mockUserManager, never()).setUserRestriction(anyString(), anyBoolean(), in testMaybeDisallowAddUsers_normalSystem_restrictionAlreadySetupForOneUser() 116 when(mockUserManager.getUsers()).thenReturn(Arrays.asList(new UserInfo[]{ in testMaybeDisallowAddUsers_splitUserSystem_meatUserDeviceOwner() 126 verify(mockUserManager).setUserRestriction(UserManager.DISALLOW_ADD_USER, true, in testMaybeDisallowAddUsers_splitUserSystem_meatUserDeviceOwner() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/ |
D | BatteryEntryTest.java | 63 @Mock private UserManager mockUserManager; field in BatteryEntryTest 82 return new BatteryEntry(mockContext, mockHandler, mockUserManager, createSipperForApp()); in createBatteryEntryForApp() 93 return new BatteryEntry(mockContext, mockHandler, mockUserManager, createSipperForSystem()); in createBatteryEntryForSystem() 147 mockUserManager, batterySipper); in batteryEntryForAOD_containCorrectInfo()
|
/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/ |
D | ContactsActor.java | 152 public MockUserManager mockUserManager; field in ContactsActor 320 return mockUserManager; in ContactsActor() 367 return mockUserManager; in ContactsActor() 389 return mockUserManager.getUserHandle(); in ContactsActor() 404 mockUserManager = new MockUserManager(mProviderContext); in ContactsActor()
|
D | ContactsProvider2Test.java | 2088 mActor.mockUserManager.setUsers(MockUserManager.PRIMARY_USER, MockUserManager.CORP_USER); in setUpCorpProvider() 2106 mActor.mockUserManager.setUsers(MockUserManager.PRIMARY_USER, MockUserManager.CORP_USER); in setUpNullCorpProvider() 2828 final MockUserManager um = mActor.mockUserManager; in testQueryCorpContactsProvider()
|
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/applications/ |
D | ApplicationDetailsFragmentTest.java | 110 UserManager mockUserManager = mock(UserManager.class); in setUp() local 111 when(mockUserManager.getUserInfo(userId)).thenReturn(userInfo); in setUp() 112 ShadowUserManager.setInstance(mockUserManager); in setUp()
|
/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/util/ |
D | UserUtilsTest.java | 45 final MockUserManager um = mActor.mockUserManager; in testGetCorpUser()
|