/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/applications/specialaccess/ |
D | AppStateAppOpsBridgeTest.java | 86 eq(UserHandle.myUserId()))) in setUp() 98 int uid = UserHandle.getUid(UserHandle.myUserId(), /* appId= */ 1); in androidPackagesIgnored() 111 int uid = UserHandle.getUid(UserHandle.myUserId(), /* appId= */ 1); in selfPackageIgnored() 124 int uid = UserHandle.getUid(UserHandle.myUserId(), /* appId= */ 1); in packagesNotRequestingPermissionIgnored() 129 UserHandle.myUserId())).thenReturn(true); in packagesNotRequestingPermissionIgnored() 140 int uid = UserHandle.getUid(UserHandle.myUserId(), /* appId= */ 1); in unavailablePackageIgnored() 144 UserHandle.myUserId())).thenReturn(false); in unavailablePackageIgnored() 155 int uid = UserHandle.getUid(UserHandle.myUserId(), /* appId= */ 1); in loadsAppOpsExtraInfo_modeAllowed_isPermissible() 170 int uid = UserHandle.getUid(UserHandle.myUserId(), /* appId= */ 1); in loadsAppOpsExtraInfo_modeDefault_isPermissible() 185 int uid = UserHandle.getUid(UserHandle.myUserId(), /* appId= */ 1); in loadsAppOpsExtraInfo_modeIgnored_isNotPermissible() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/ |
D | RecentAppStatsMixinTest.java | 100 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_oneValidRecentAppSet_shouldHaveOneRecentApp() 131 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_threeValidRecentAppsSet_shouldHaveThreeRecentApps() 133 when(mAppState.getEntry(stat2.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_threeValidRecentAppsSet_shouldHaveThreeRecentApps() 135 when(mAppState.getEntry(stat3.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_threeValidRecentAppsSet_shouldHaveThreeRecentApps() 167 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_oneValidAndTwoInvalidSet_shouldHaveOneRecentApp() 169 when(mAppState.getEntry(stat2.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_oneValidAndTwoInvalidSet_shouldHaveOneRecentApp() 171 when(mAppState.getEntry(stat3.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_oneValidAndTwoInvalidSet_shouldHaveOneRecentApp() 198 when(mAppState.getEntry(stat.mPackageName, UserHandle.myUserId())).thenReturn(statEntry); in loadDisplayableRecentApps_oneInstantAppSet_shouldHaveOneRecentApp() 226 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_withNullAppEntryOrInfo_shouldNotCrash() 228 when(mAppState.getEntry(stat2.mPackageName, UserHandle.myUserId())) in loadDisplayableRecentApps_withNullAppEntryOrInfo_shouldNotCrash() [all …]
|
/packages/apps/Settings/src/com/android/settings/notification/ |
D | RedactNotificationPreferenceController.java | 75 mProfileUserId = UserHandle.myUserId(); in RedactNotificationPreferenceController() 76 final int[] profileIds = mUm.getProfileIdsWithDisabled(UserHandle.myUserId()); in RedactNotificationPreferenceController() 79 if (profileId != UserHandle.myUserId()) { in RedactNotificationPreferenceController() 91 ? UserHandle.myUserId() : mProfileUserId; in displayPreference() 100 ? UserHandle.myUserId() : mProfileUserId; in isChecked() 108 ? UserHandle.myUserId() : mProfileUserId; in setChecked() 119 && mProfileUserId == UserHandle.myUserId()) { in getAvailabilityStatus() 124 ? UserHandle.myUserId() : mProfileUserId; in getAvailabilityStatus()
|
/packages/apps/TvSettings/Settings/tests/robotests/src/com/android/tv/settings/device/apps/ |
D | RecentAppsPreferenceControllerTest.java | 157 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in display_showRecents() 159 when(mAppState.getEntry(stat2.mPackageName, UserHandle.myUserId())) in display_showRecents() 161 when(mAppState.getEntry(stat3.mPackageName, UserHandle.myUserId())) in display_showRecents() 196 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())).thenReturn(stat1Entry); in display_showRecentsWithInstantApp() 197 when(mAppState.getEntry(stat2.mPackageName, UserHandle.myUserId())).thenReturn(stat2Entry); in display_showRecentsWithInstantApp() 234 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in display_showRecentsWithNullAppEntryOrInfo() 236 when(mAppState.getEntry(stat2.mPackageName, UserHandle.myUserId())) in display_showRecentsWithNullAppEntryOrInfo() 260 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in display_hasRecentButNoneDisplayable_showAllApps() 262 when(mAppState.getEntry(stat2.mPackageName, UserHandle.myUserId())) in display_hasRecentButNoneDisplayable_showAllApps() 282 when(mAppState.getEntry(stat1.mPackageName, UserHandle.myUserId())) in display_showRecents_formatSummary()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/appinfo/ |
D | ExternalSourcesDetailsTest.java | 129 shadowUserManager.setUserRestriction(UserHandle.of(UserHandle.myUserId()), in refreshUi_userRestrictionsUnknownSources_disablesSwitchPreference() 143 UserHandle.of(UserHandle.myUserId()))).isTrue(); in refreshUi_userRestrictionsUnknownSources_disablesSwitchPreference() 168 shadowUserManager.setUserRestriction(UserHandle.of(UserHandle.myUserId()), in refreshUi_userRestrictionsUnknownSourcesGlobally_disablesSwitchPreference() 182 UserHandle.of(UserHandle.myUserId()))).isTrue(); in refreshUi_userRestrictionsUnknownSourcesGlobally_disablesSwitchPreference() 207 shadowUserManager.setUserRestriction(UserHandle.of(UserHandle.myUserId()), in refreshUi_bothUnknownSourcesUserRestrictions_disableSwitchPreference() 209 shadowUserManager.setUserRestriction(UserHandle.of(UserHandle.myUserId()), in refreshUi_bothUnknownSourcesUserRestrictions_disableSwitchPreference() 223 UserHandle.of(UserHandle.myUserId()))).isTrue(); in refreshUi_bothUnknownSourcesUserRestrictions_disableSwitchPreference() 226 UserHandle.of(UserHandle.myUserId()))).isTrue(); in refreshUi_bothUnknownSourcesUserRestrictions_disableSwitchPreference()
|
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/display/ |
D | BrightnessLevelPreferenceControllerTest.java | 87 Settings.System.SCREEN_BRIGHTNESS, mMin, UserHandle.myUserId()); in testRefreshUi_minValue() 96 Settings.System.SCREEN_BRIGHTNESS, mMax, UserHandle.myUserId()); in testRefreshUi_maxValue() 105 Settings.System.SCREEN_BRIGHTNESS, mMid, UserHandle.myUserId()); in testRefreshUi_midValue() 117 Settings.System.SCREEN_BRIGHTNESS, UserHandle.myUserId()); in testHandlePreferenceChanged_minValue() 125 Settings.System.SCREEN_BRIGHTNESS, UserHandle.myUserId()); in testHandlePreferenceChanged_maxValue() 133 Settings.System.SCREEN_BRIGHTNESS, UserHandle.myUserId()); in testHandlePreferenceChanged_midValue()
|
/packages/apps/Car/Settings/src/com/android/car/settings/storage/ |
D | StorageFileCategoryPreferenceController.java | 59 StorageAsyncLoader.AppsStorageResult data = result.get(UserHandle.myUserId()); in calculateCategoryUsage() 67 int myUserId = UserHandle.myUserId(); in handlePreferenceClicked() local 69 intent.putExtra(Intent.EXTRA_USER_ID, myUserId); in handlePreferenceClicked() 71 getContext().startActivityAsUser(intent, UserHandle.of(myUserId)); in handlePreferenceClicked()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/ |
D | RedactionInterstitialTest.java | 111 UserHandle.myUserId(), UserHandle.myUserId(), in managedProfileNoRestrictionsTest() 126 UserHandle.myUserId(), UserHandle.myUserId(), in managedProfileUnredactedRestrictionTest() 148 LOCK_SCREEN_SHOW_NOTIFICATIONS, show, UserHandle.myUserId()); in setupSettings() 150 LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS, showUnredacted, UserHandle.myUserId()); in setupSettings()
|
D | SoundWorkSettingsControllerTest.java | 90 .thenReturn(UserHandle.myUserId()); in isAvailable_managedProfileAndNotSingleVolume_shouldReturnTrue() 108 .thenReturn(UserHandle.myUserId()); in isAvailable_singleVolume_shouldReturnFalse() 130 .thenReturn(UserHandle.myUserId()); in onResume_noVoiceCapability_shouldHidePhoneRingtone() 154 .thenReturn(UserHandle.myUserId()); in onResume_availableButLocked_shouldRedactPreferences()
|
/packages/apps/Settings/src/com/android/settings/users/ |
D | UserSettings.java | 282 final int myUserId = UserHandle.myUserId(); in onCreate() local 285 mMePreference = new UserPreference(getPrefContext(), null /* attrs */, myUserId); in onCreate() 370 UserManager.DISALLOW_REMOVE_USER, UserHandle.myUserId()); in onCreateOptionsMenu() 381 onRemoveUserClicked(UserHandle.myUserId()); in onOptionsItemSelected() 423 UserInfo user = mUserManager.getUserInfo(UserHandle.myUserId()); in loadProfile() 438 int myUserId = UserHandle.myUserId(); in finishLoadProfile() local 439 Bitmap b = mUserManager.getUserIcon(myUserId); in finishLoadProfile() 442 mUserIcons.put(myUserId, b); in finishLoadProfile() 448 return lpu.isSecure(UserHandle.myUserId()); in hasLockscreenSecurity() 770 if (mRemovingUserId == UserHandle.myUserId()) { [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/location/ |
D | LocationInjectedServicesPreferenceControllerTest.java | 119 new int[]{UserHandle.myUserId(), fakeWorkProfileId}); in workProfileDisallowShareLocationOn_getParentUserLocationServicesOnly() 135 any(Context.class), eq(UserHandle.myUserId())); in workProfileDisallowShareLocationOn_getParentUserLocationServicesOnly() 142 new int[]{UserHandle.myUserId(), fakeWorkProfileId}); in workProfileDisallowShareLocationOff_getAllUserLocationServices() 172 map.put(UserHandle.myUserId(), preferences); in withUserRestriction_shouldDisableLocationAccuracy() 175 ShadowUserManager.getShadow().setProfileIdsWithDisabled(new int[]{UserHandle.myUserId()}); in withUserRestriction_shouldDisableLocationAccuracy() 177 final int userId = UserHandle.myUserId(); in withUserRestriction_shouldDisableLocationAccuracy()
|
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/notifications/ |
D | RecentNotificationsAppsPreferenceControllerTest.java | 138 when(mMockApplicationsState.getEntry(app1.getPackageName(), UserHandle.myUserId())) in areEvents_showValidRecents() 140 when(mMockApplicationsState.getEntry(app2.getPackageName(), UserHandle.myUserId())) in areEvents_showValidRecents() 142 when(mMockApplicationsState.getEntry(app3.getPackageName(), UserHandle.myUserId())) in areEvents_showValidRecents() 184 when(mMockApplicationsState.getEntry(app1.getPackageName(), UserHandle.myUserId())) in areEvents_showMaximumRecents() 186 when(mMockApplicationsState.getEntry(app2.getPackageName(), UserHandle.myUserId())) in areEvents_showMaximumRecents() 188 when(mMockApplicationsState.getEntry(app3.getPackageName(), UserHandle.myUserId())) in areEvents_showMaximumRecents() 190 when(mMockApplicationsState.getEntry(app4.getPackageName(), UserHandle.myUserId())) in areEvents_showMaximumRecents()
|
/packages/apps/Settings/src/com/android/settings/ |
D | UserCredentialsSettings.java | 149 final int myUserId = UserHandle.myUserId(); in onCreateDialog() local 151 myUserId)) { in onCreateDialog() 155 .checkIfRestrictionEnforced(getContext(), restriction, myUserId); in onCreateDialog() 272 final int myUserId = UserHandle.myUserId(); in doInBackground() local 273 final int systemUid = UserHandle.getUid(myUserId, Process.SYSTEM_UID); in doInBackground() 274 final int wifiUid = UserHandle.getUid(myUserId, Process.WIFI_UID); in doInBackground() 280 if (myUserId == 0) { in doInBackground()
|
D | Utils.java | 443 final int myUserId = UserHandle.myUserId(); in getManagedProfileWithDisabled() local 444 final List<UserInfo> profiles = userManager.getProfiles(myUserId); in getManagedProfileWithDisabled() 449 && profile.getUserHandle().getIdentifier() != myUserId) { in getManagedProfileWithDisabled() 481 return UserHandle.myUserId(); in getCurrentUserId() 501 final UserHandle currentUser = new UserHandle(UserHandle.myUserId()); in getSecureTargetUser() 561 return (UserHandle.myUserId() == otherUser.getIdentifier()) in isProfileOf() 691 final int userId = bundle.getInt(Intent.EXTRA_USER_ID, UserHandle.myUserId()); in getUserIdFromBundle() 705 if (UserHandle.myUserId() == UserHandle.USER_SYSTEM) { in enforceSystemUser() 709 + "USER_SYSTEM, but current user is " + UserHandle.myUserId()); in enforceSystemUser() 719 final int[] profileIds = um.getProfileIdsWithDisabled(UserHandle.myUserId()); in enforceSameOwner() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/development/ |
D | UsbAudioRoutingPreferenceControllerTest.java | 79 UserHandle.myUserId())).thenReturn(true); in updateState_usbAudioRoutingEnabled_shouldCheckedPreference() 93 UserHandle.myUserId())).thenReturn(true); in updateState_usbAudioRoutingDisabled_shouldUncheckedPreference() 107 UserHandle.myUserId())).thenReturn(false); in updateState_usbDataSignalingDisabled_shouldDisablePreference() 154 UserHandle.myUserId())).thenReturn(true); in onDeveloperOptionsSwitchEnabled_usbEnabled_shouldNotDisablePreference() 165 UserHandle.myUserId())).thenReturn(false); in onDeveloperOptionsSwitchEnabled_usbDisabled_shouldDisablePreference()
|
D | DefaultUsbConfigurationPreferenceControllerTest.java | 75 UserHandle.myUserId())).thenReturn(true); in updateState_usbDataSignalingEnabled_shouldNotDisablePreference() 86 UserHandle.myUserId())).thenReturn(false); in updateState_usbDataSignalingDisabled_shouldDisablePreference() 98 UserHandle.myUserId())).thenReturn(true); in onDeveloperOptionsSwitchEnabled_usbEnabled_shouldNotDisablePreference() 109 UserHandle.myUserId())).thenReturn(false); in onDeveloperOptionsSwitchEnabled_usbDisabled_shouldDisablePreference()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/testutils/shadow/ |
D | ShadowLockPatternUtils.java | 121 sUserToComplexityMap.put(UserHandle.myUserId(), complexity); in setRequiredPasswordComplexity() 125 sUserToProfileComplexityMap.put(UserHandle.myUserId(), complexity); in setRequiredProfilePasswordComplexity() 140 sUserToMetricsMap.put(UserHandle.myUserId(), metrics); in setRequestedPasswordMetrics() 144 sUserToProfileMetricsMap.put(UserHandle.myUserId(), metrics); in setRequestedProfilePasswordMetrics()
|
/packages/apps/Settings/src/com/android/settings/security/ |
D | ScreenPinningSettings.java | 124 int defaultValueIfSettingNull = mLockPatternUtils.isSecure(UserHandle.myUserId()) ? 1 : 0; in isScreenLockUsed() 135 .getKeyguardStoredPasswordQuality(UserHandle.myUserId()); in setScreenLockUsed() 160 UserHandle.myUserId()) in onActivityResult() 170 UserHandle.myUserId()); in getCurrentSecurityTitle() 181 if (mLockPatternUtils.isLockPatternEnabled(UserHandle.myUserId())) { in getCurrentSecurityTitle()
|
/packages/apps/Settings/tests/unit/src/com/android/settings/homepage/contextualcards/slices/ |
D | FaceSetupSliceTest.java | 68 when(faceManager.hasEnrolledTemplates(UserHandle.myUserId())).thenReturn(true); in getSlice_faceEnrolled_noReEnroll_shouldReturnNull() 83 when(faceManager.hasEnrolledTemplates(UserHandle.myUserId())).thenReturn(false); in getSlice_faceNotEnrolled_shouldReturnSlice() 94 when(faceManager.hasEnrolledTemplates(UserHandle.myUserId())).thenReturn(true); in getSlice_faceEnrolled_shouldReEnroll_shouldReturnSlice() 107 when(faceManager.hasEnrolledTemplates(UserHandle.myUserId())).thenReturn(true); in getSlice_faceEnrolled_musteEnroll_shouldReturnSlice()
|
/packages/apps/ManagedProvisioning/src/com/android/managedprovisioning/provisioning/ |
D | ProvisioningControllerFactory.java | 46 ? UserHandle.USER_SYSTEM : UserHandle.myUserId(); in createProvisioningController() 58 UserHandle.myUserId(), in createProvisioningController() 64 UserHandle.myUserId(), in createProvisioningController()
|
/packages/apps/Bluetooth/src/com/android/bluetooth/util/ |
D | DevicePolicyUtils.java | 35 final int myUserId = UserHandle.myUserId(); in isBluetoothWorkContactSharingDisabled() local 36 final List<UserInfo> userInfoList = userManager.getProfiles(myUserId); in isBluetoothWorkContactSharingDisabled()
|
/packages/modules/Permission/PermissionController/tests/outofprocess/src/com/android/permissioncontroller/tests/outofprocess/ |
D | DumpTest.kt | 20 import android.os.UserHandle.myUserId 58 assertThat(dump.autoRevoke.usersList.map { it.userId }).contains(myUserId()) in autoRevokeDumpHasCurrentUser() 68 assertThat(dump.autoRevoke.usersList[myUserId()].packagesList.map { it.packageName }) in autoRevokeDumpHasAndroidPackage()
|
/packages/apps/Settings/src/com/android/settings/notification/app/ |
D | VisibilityPreferenceController.java | 159 final UserInfo parentUser = mUm.getProfileParent(UserHandle.myUserId()); in getLockscreenNotificationsEnabled() 160 final int primaryUserId = parentUser != null ? parentUser.id : UserHandle.myUserId(); in getLockscreenNotificationsEnabled() 171 boolean lockscreenSecure = mLockPatternUtils.isSecure(UserHandle.myUserId()); in isLockScreenSecure() 172 UserInfo parentUser = mUm.getProfileParent(UserHandle.myUserId()); in isLockScreenSecure()
|
/packages/apps/ThemePicker/src/com/android/customization/model/theme/custom/ |
D | IconOptionsProvider.java | 61 OVERLAY_CATEGORY_ICON_SYSUI, UserHandle.myUserId(), targetPackages)); in IconOptionsProvider() 63 OVERLAY_CATEGORY_ICON_SETTINGS, UserHandle.myUserId(), targetPackages)); in IconOptionsProvider() 65 OVERLAY_CATEGORY_ICON_LAUNCHER, UserHandle.myUserId(), targetPackages)); in IconOptionsProvider() 67 OVERLAY_CATEGORY_ICON_THEMEPICKER, UserHandle.myUserId(), targetPackages)); in IconOptionsProvider()
|
/packages/apps/Settings/src/com/android/settings/security/trustagent/ |
D | TrustAgentManager.java | 109 final int myUserId = UserHandle.myUserId(); in getActiveTrustAgents() local 116 final List<ComponentName> enabledTrustAgents = utils.getEnabledTrustAgents(myUserId); in getActiveTrustAgents() 119 context, DevicePolicyManager.KEYGUARD_DISABLE_TRUST_AGENTS, myUserId); in getActiveTrustAgents()
|