/packages/services/Car/tests/carservice_unit_test/src/com/android/car/user/ |
D | UserLifecycleEventFilterTest.java | 65 assertThrows(NullPointerException.class, () -> builder.addUser(null)); in testAddUser_nullUser_throws() 72 assertThrows(IllegalArgumentException.class, ()-> builder.addUser(UserHandle.ALL)); in testAddUser_specialUserHandle_throws() 74 ()-> builder.addUser(UserHandle.CURRENT_OR_SELF)); in testAddUser_specialUserHandle_throws() 76 ()-> builder.addUser(UserHandle.of(UserHandle.USER_NULL))); in testAddUser_specialUserHandle_throws() 99 .addUser(USER111).addUser(USER111).addUser(USER113).addUser(USER111).build(); in testBuild_duplicateUserIdsIgnored() 107 .addUser(UserHandle.CURRENT).build(); in testBuild_currentUser_notEvaluatedAtFilterCreation() 118 .addUser(USER111).build(); in testApply_nullEvent_throws() 145 .addUser(USER111).build(); in testApply_userIdMatches_returnsTrue() 153 .addUser(USER112).build(); in testApply_previousUserIdMatches_returnsTrue() 162 .addUser(USER112).addUser(USER113).build(); in testApply_userIdsDoNotMatch_returnsFalse() [all …]
|
D | AppLifecycleListenerTest.java | 49 new UserLifecycleEventFilter.Builder().addUser(USER111).build();
|
D | CarUserServiceTest.java | 366 .addUser(UserHandle.of(mAdminUserId)).build(), mockListener2); in testOnUserLifecycleEvent_notifyListener_nonNullFilter() 369 .addUser(UserHandle.of(mRegularUserId)).build(), mockListener3); in testOnUserLifecycleEvent_notifyListener_nonNullFilter() 600 .addUser(UserHandle.of(mRegularUserId)).build(), in testOnUserLifecycleEvent_notifyReceiver_nonNullFilter() 622 new UserLifecycleEventFilter.Builder().addUser(UserHandle.of(mRegularUserId)) in testOnUserLifecycleEvent_notifyReceiver_singleReceiverWithMultipleFilters()
|
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/security/ |
D | SecurityEntryPreferenceControllerTest.java | 59 getShadowUserManager().addUser(UserHandle.myUserId(), "name", UserInfo.FLAG_GUEST); in getAvailabilityStatus_guestUser_disabledForUser() 67 getShadowUserManager().addUser(UserHandle.myUserId(), "name", UserInfo.FLAG_GUEST); in getAvailabilityStatus_guestUser_disabledForUser_zoneWrite() 75 getShadowUserManager().addUser(UserHandle.myUserId(), "name", UserInfo.FLAG_GUEST); in getAvailabilityStatus_guestUser_disabledForUser_zoneRead() 83 getShadowUserManager().addUser(UserHandle.myUserId(), "name", UserInfo.FLAG_GUEST); in getAvailabilityStatus_guestUser_disabledForUser_zoneHidden() 90 getShadowUserManager().addUser(UserHandle.myUserId(), "name", /* flags= */ 0); in getAvailabilityStatus_nonGuestUser_available() 98 getShadowUserManager().addUser(UserHandle.myUserId(), "name", /* flags= */ 0); in getAvailabilityStatus_nonGuestUser_available_zoneWrite() 106 getShadowUserManager().addUser(UserHandle.myUserId(), "name", /* flags= */ 0); in getAvailabilityStatus_nonGuestUser_available_zoneRead() 114 getShadowUserManager().addUser(UserHandle.myUserId(), "name", /* flags= */ 0); in getAvailabilityStatus_nonGuestUser_available_zoneHidden()
|
/packages/modules/IntentResolver/tests/unit/src/com/android/intentresolver/data/repository/ |
D | FakeUserRepositoryTest.kt | 43 fun addUser() = runTest { in <lambda>() method 49 repo.addUser(personalUser, true) in <lambda>() 52 repo.addUser(workUser, false) in <lambda>() 105 repo.addUser(workUser, true) in <lambda>()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/specialaccess/interactacrossprofiles/ |
D | InteractAcrossProfilesSettingsTest.java | 103 mShadowUserManager.addUser( in collectConfigurableApps_fromPersonal_returnsCombinedPackages() 128 mShadowUserManager.addUser( in collectConfigurableApps_fromWork_returnsCombinedPackages() 154 mShadowUserManager.addUser( in collectConfigurableApps_onlyOneProfile_returnsEmpty() 169 mShadowUserManager.addUser( in getNumberOfEnabledApps_returnsNumberOfEnabledApps()
|
D | InteractAcrossProfilesDetailsTest.java | 79 mShadowUserManager.addUser( in getPreferenceSummary_appOpAllowed_returnsAllowed() 102 mShadowUserManager.addUser( in getPreferenceSummary_appOpNotAllowed_returnsNotAllowed() 125 mShadowUserManager.addUser( in getPreferenceSummary_noWorkProfile_returnsNotAllowed()
|
D | InteractAcrossProfilesControllerTest.java | 51 shadowOf(mUserManager).addUser( in getAvailabilityStatus_multipleProfiles_returnsAvailable() 65 shadowOf(mUserManager).addUser( in getAvailabilityStatus_oneProfile_returnsDisabled()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/ |
D | SilentStatusBarPreferenceControllerTest.java | 78 um.addUser(UserHandle.myUserId(), "Another User", UserInfo.FLAG_FULL); in isAvailable_extraUser_available() 86 um.addUser(UserHandle.myUserId(), "Guest", UserInfo.FLAG_GUEST); in isAvailable_guestUser_disabled()
|
/packages/modules/IntentResolver/tests/unit/src/com/android/intentresolver/domain/interactor/ |
D | UserInteractorTest.kt | 95 fakeUserRepo.addUser(cloneUser, available = true) in <lambda>() 151 userRepo.addUser(workUser, false) in <lambda>()
|
/packages/apps/Settings/src/com/android/settings/users/ |
D | UserSettings.java | 1495 private void updateAddUserCommon(Context context, RestrictedPreference addUser, 1500 addUser.setVisible(true); 1501 addUser.setSelectable(true); 1506 addUser.setEnabled(canAddMoreUsers && !mAddingUser && canSwitchUserNow()); 1509 addUser.setSummary(getString(R.string.user_add_max_count)); 1511 addUser.setSummary(null); 1513 if (addUser.isEnabled()) { 1514 addUser.setDisabledByAdmin( 1518 addUser.setVisible(false);
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/dashboard/ |
D | DashboardFeatureProviderImplTest.java | 713 ShadowUserManager.getShadow().addUser(10, "Someone", 0); in openTileIntent_profileSelectionDialog_shouldShow() 729 ShadowUserManager.getShadow().addUser(10, "Someone", 0); in openTileIntent_profileSelectionDialog_explicitMetadataShouldShow() 746 ShadowUserManager.getShadow().addUser(10, "Someone", 0); in openTileIntent_profileSelectionDialog_shouldNotShow() 764 ShadowUserManager.getShadow().addUser(userId, "Someone", 0); in openTileIntent_profileSelectionDialog_validUserHandleShouldNotShow() 785 ShadowUserManager.getShadow().addUser(10, "Someone", 0); in openTileIntent_profileSelectionDialog_invalidUserHandleShouldShow() 804 ShadowUserManager.getShadow().addUser(userId, "Someone", 0); in openTileIntent_profileSelectionDialog_unresolvableWorkProfileIntentShouldNotShow()
|
/packages/modules/IntentResolver/tests/shared/src/com/android/intentresolver/data/repository/ |
D | FakeUserRepository.kt | 33 fun addUser(user: User, available: Boolean) { in <lambda>() method
|
/packages/apps/Settings/tests/robotests/testutils/com/android/settings/testutils/shadow/ |
D | ShadowUserManager.java | 95 @Override public UserHandle addUser(int id, String name, int flags) { in addUser() method in ShadowUserManager 96 UserHandle userHandle = super.addUser(id, name, flags); in addUser()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/system/ |
D | FactoryResetDemoUserPreferenceControllerTest.java | 87 mShadowUserManager.addUser(UserHandle.myUserId(), "test", UserInfo.FLAG_DEMO); in isAvailable_demoUser()
|
/packages/apps/ManagedProvisioning/tests/robotests/src/com/android/managedprovisioning/task/interactacrossprofiles/ |
D | CrossProfileAppsSnapshotTest.java | 61 shadowOf(mUserManager).addUser(TEST_USER_ID, "Username", /* flags= */ 0); in setUp()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/users/ |
D | MultiUserSwitchBarControllerTest.java | 88 mUserManager.addUser(10, "Test", UserInfo.FLAG_ADMIN); in onStart_userIsNotMain_shouldNotBeEnabled()
|
/packages/modules/DeviceLock/tests/unittests/src/com/android/server/devicelock/ |
D | DeviceLockServiceImplTest.java | 162 mSystemUser = mShadowUserManager.addUser(USER_SYSTEM, SYSTEM_USER_NAME, /* flags= */ 0); in setup() 163 mSecondaryUser = mShadowUserManager.addUser(USER_SECONDARY, SECONDARY_USER_NAME, in setup()
|
/packages/apps/ManagedProvisioning/tests/robotests/src/com/android/managedprovisioning/task/ |
D | UpdateInteractAcrossProfilesAppOpTaskTest.java | 88 shadowOf(mUserManager).addUser(TEST_USER_ID, "Username", /* flags= */ 0); in setUp()
|
/packages/services/Car/tests/android_car_api_test/src/android/car/apitest/ |
D | CarUserManagerLifecycleEventFilterTest.java | 83 .addUser(UserHandle.CURRENT)
|
D | CarUserManagerTest.java | 155 .addUser(UserHandle.of(newUserId)).build(); in testLifecycleMultipleListeners()
|
/packages/services/Car/car-lib/src/android/car/user/ |
D | UserLifecycleEventFilter.java | 174 public Builder addUser(@NonNull UserHandle userHandle) { in addUser() method in UserLifecycleEventFilter.Builder
|
/packages/apps/Car/Cluster/ClusterHomeSample/src/com/android/car/cluster/home/ |
D | ClusterHomeApplication.java | 212 .addUser(UserHandle.CURRENT) in initClusterHome()
|
/packages/modules/IntentResolver/tests/activity/src/com/android/intentresolver/ |
D | ResolverActivityTest.java | 1089 mFakeUserRepo.addUser( in markOtherProfileAvailability() 1093 mFakeUserRepo.addUser( in markOtherProfileAvailability()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/biometrics/face/ |
D | FaceEnrollIntroductionTest.java | 633 mUserManager.addUser(10, "", 0); in testFaceEnrollIntroduction_maxFacesNotEnrolled_addUserProfile()
|