Home
last modified time | relevance | path

Searched refs:pm (Results 1 – 25 of 1450) sorted by relevance

12345678910>>...58

/cts/hostsidetests/appsecurity/test-apps/InstantCookieApp/src/test/instant/cookie/
DCookieTest.java24 import android.content.pm.PackageManager;
36 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in testCookieUpdateAndRetrieval() local
39 assertTrue(pm.isInstantApp()); in testCookieUpdateAndRetrieval()
42 assertTrue(pm.getInstantAppCookieMaxBytes() > 0); in testCookieUpdateAndRetrieval()
45 byte[] cookie = pm.getInstantAppCookie(); in testCookieUpdateAndRetrieval()
49 pm.updateInstantAppCookie("1".getBytes()); in testCookieUpdateAndRetrieval()
53 pm.updateInstantAppCookie( in testCookieUpdateAndRetrieval()
54 new byte[pm.getInstantAppCookieMaxBytes() + 1]); in testCookieUpdateAndRetrieval()
61 assertEquals("1", new String(pm.getInstantAppCookie())); in testCookieUpdateAndRetrieval()
66 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in testCookiePersistedAcrossInstantInstalls1() local
[all …]
/cts/common/device-side/bedstead/testapisreflection/java/apis/
Dallowlisted-test-fields.txt1 android.content.pm.UserInfo,id,int
2 android.content.pm.UserInfo,name,String
3 android.content.pm.UserInfo,iconPath,String
4 android.content.pm.UserInfo,flags,int
5 android.content.pm.UserInfo,userType,String
6 android.content.pm.UserInfo,serialNumber,int
7 android.content.pm.UserInfo,creationTime,long
8 android.content.pm.UserInfo,lastLoggedInTime,long
9 android.content.pm.UserInfo,lastLoggedInFingerprint,String
10 android.content.pm.UserInfo,partial,boolean
[all …]
Dallowlisted-test-methods.txt28 android.content.pm.CrossProfileApps,public boolean canConfigureInteractAcrossProfiles(java.lang.Str…
33 android.content.pm.PackageManager,public void setKeepUninstalledPackages(java.util.List<java.lang.S…
37 android.content.pm.PackageInstaller.SessionParams,public void setInstallFlagAllowTest()
39 android.content.pm.UserInfo,public boolean supportsSwitchTo()
41 android.os.UserManager,public java.util.List<android.content.pm.UserInfo> getUsers()
42 android.os.UserManager,public java.util.List<android.content.pm.UserInfo> getUsers(boolean, boolean…
43 android.content.pm.UserInfo,public boolean isPrimary()
44 android.content.pm.UserInfo,public boolean isAdmin()
45 android.content.pm.UserInfo,public boolean isGuest()
46 android.content.pm.UserInfo,public boolean isRestricted()
[all …]
/cts/hostsidetests/appsecurity/test-apps/ApplicationVisibilityCrossUserApp/src/com/android/cts/applicationvisibility/
DApplicationVisibilityCrossUserTest.java18 import static android.content.pm.PackageManager.MATCH_KNOWN_PACKAGES;
26 import android.content.pm.ApplicationInfo;
27 import android.content.pm.PackageInfo;
28 import android.content.pm.PackageManager;
59 final PackageManager pm = mContext.getPackageManager(); in testPackageVisibility_currentUser() local
61 pm.getInstalledPackagesAsUser(0, mContext.getUserId()); in testPackageVisibility_currentUser()
68 final PackageManager pm = mContext.getPackageManager(); in testPackageVisibility_anyUserCrossUserGrant() local
70 pm.getInstalledPackagesAsUser(MATCH_KNOWN_PACKAGES, mContext.getUserId()); in testPackageVisibility_anyUserCrossUserGrant()
77 final PackageManager pm = mContext.getPackageManager(); in testPackageVisibility_anyUserCrossUserNoGrant() local
81 pm.getInstalledPackagesAsUser(MATCH_KNOWN_PACKAGES, mContext.getUserId()); in testPackageVisibility_anyUserCrossUserNoGrant()
[all …]
/cts/apps/CtsVerifier/src/com/android/cts/verifier/features/
DFeatureUtil.java20 import android.content.pm.PackageManager;
120 PackageManager pm = context.getPackageManager(); in isDataRoamingSupported() local
121 return pm.hasSystemFeature(PackageManager.FEATURE_TELEPHONY) && !isWatch(context); in isDataRoamingSupported()
163 PackageManager pm = context.getPackageManager(); in isWatch() local
164 return pm.hasSystemFeature(PackageManager.FEATURE_WATCH); in isWatch()
171 PackageManager pm = context.getPackageManager(); in isTelevision() local
172 return pm.hasSystemFeature(PackageManager.FEATURE_LEANBACK); in isTelevision()
179 PackageManager pm = context.getPackageManager(); in isWatchOrAutomotive() local
180 return pm.hasSystemFeature(PackageManager.FEATURE_WATCH) in isWatchOrAutomotive()
181 || pm.hasSystemFeature(PackageManager.FEATURE_AUTOMOTIVE); in isWatchOrAutomotive()
[all …]
/cts/hostsidetests/appsecurity/test-apps/V3SigningSchemeRotation/src/android/appsecurity/cts/v3rotationtests/
DV3RotationTest.java21 import android.content.pm.PackageInfo;
22 import android.content.pm.PackageManager;
23 import android.content.pm.Signature;
167 PackageManager pm = getContext().getPackageManager(); in testHasPerm() local
169 pm.checkPermission(PERMISSION_NAME, COMPANION_PKG) in testHasPerm()
174 PackageManager pm = getContext().getPackageManager(); in testHasNoPerm() local
176 pm.checkPermission(PERMISSION_NAME, COMPANION_PKG) in testHasNoPerm()
184 PackageManager pm = getContext().getPackageManager(); in testGetSignaturesShowsOld() local
185 PackageInfo pi = pm.getPackageInfo(PKG, PackageManager.GET_SIGNATURES); in testGetSignaturesShowsOld()
196 PackageManager pm = getContext().getPackageManager(); in testGetSigningCertificatesShowsAll() local
[all …]
/cts/hostsidetests/appsecurity/test-apps/PackageAccessApp/src/com/android/cts/packageaccessapp/
DPackageAccessTest.java22 import android.content.pm.PackageInfo;
23 import android.content.pm.PackageManager;
24 import android.content.pm.PackageManager.NameNotFoundException;
50 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in testPackageAccess_inUser() local
52 PackageInfo pi = pm.getPackageInfo(TINY_PKG, 0); in testPackageAccess_inUser()
61 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in testPackageAccess_inUserUninstalled() local
63 PackageInfo pi = pm.getPackageInfo(TINY_PKG, PackageManager.MATCH_UNINSTALLED_PACKAGES); in testPackageAccess_inUserUninstalled()
72 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in testPackageAccess_notInOtherUser() local
74 PackageInfo pi = pm.getPackageInfo(TINY_PKG, 0); in testPackageAccess_notInOtherUser()
83 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in testPackageAccess_notInOtherUserUninstalled() local
[all …]
/cts/tests/tests/content/src/android/content/pm/cts/
DPackageItemInfo_DisplayNameComparatorTest.java17 package android.content.pm.cts;
21 import android.content.pm.ActivityInfo;
22 import android.content.pm.PackageItemInfo;
23 import android.content.pm.PackageManager;
24 import android.content.pm.PackageItemInfo.DisplayNameComparator;
25 import android.content.pm.PackageManager.NameNotFoundException;
36 PackageManager pm = getContext().getPackageManager(); in testDisplayNameComparator() local
37 DisplayNameComparator comparator = new DisplayNameComparator(pm); in testDisplayNameComparator()
40 ActivityInfo activityInfo = pm.getActivityInfo(componentName, 0); in testDisplayNameComparator()
44 activityInfo = pm.getActivityInfo(componentName, 0); in testDisplayNameComparator()
DApplicationInfo_DisplayNameComparatorTest.java17 package android.content.pm.cts;
19 import android.content.pm.ApplicationInfo;
20 import android.content.pm.ApplicationInfo.DisplayNameComparator;
21 import android.content.pm.PackageManager;
22 import android.content.pm.PackageManager.NameNotFoundException;
41 PackageManager pm = getContext().getPackageManager(); in testConstructor() local
42 new DisplayNameComparator(pm); in testConstructor()
48 PackageManager pm = getContext().getPackageManager(); in testCompare() local
49 mDisplayNameComparator = new ApplicationInfo.DisplayNameComparator(pm); in testCompare()
DPermissionGroupInfoTest.java17 package android.content.pm.cts;
20 import android.content.pm.PackageManager;
21 import android.content.pm.PermissionGroupInfo;
22 import android.content.pm.PackageManager.NameNotFoundException;
34 PackageManager pm = getContext().getPackageManager(); in testPermissionGroupInfo() local
38 PermissionGroupInfo permissionGroupInfo = pm in testPermissionGroupInfo()
46 assertEquals(GROUP_NAME, permissionGroupInfo.loadLabel(pm)); in testPermissionGroupInfo()
47 assertEquals(GROUP_DESCRIPTION, permissionGroupInfo.loadDescription(pm)); in testPermissionGroupInfo()
DPermissionFeatureTest.java17 package android.content.pm.cts;
19 import android.content.pm.PackageManager;
74 final PackageManager pm = getContext().getPackageManager(); in assertPermissionGranted() local
76 pm.checkPermission(permName, getContext().getPackageName())); in assertPermissionGranted()
80 final PackageManager pm = getContext().getPackageManager(); in assertPermissionDenied() local
82 pm.checkPermission(permName, getContext().getPackageName())); in assertPermissionDenied()
/cts/tests/tests/wifi/src/android/net/wifi/cts/
DWifiFeature.java20 import android.content.pm.PackageManager;
34 final PackageManager pm = context.getPackageManager(); in isTelephonySupported() local
35 return pm.hasSystemFeature(PackageManager.FEATURE_TELEPHONY); in isTelephonySupported()
39 final PackageManager pm = context.getPackageManager(); in isRttSupported() local
40 return pm.hasSystemFeature(PackageManager.FEATURE_WIFI_RTT); in isRttSupported()
44 final PackageManager pm = context.getPackageManager(); in isAwareSupported() local
45 return pm.hasSystemFeature(PackageManager.FEATURE_WIFI_AWARE); in isAwareSupported()
/cts/tests/tests/wifi/src/android/net/wifi/nl80211/cts/
DWifiFeature.java20 import android.content.pm.PackageManager;
34 final PackageManager pm = context.getPackageManager(); in isTelephonySupported() local
35 return pm.hasSystemFeature(PackageManager.FEATURE_TELEPHONY); in isTelephonySupported()
39 final PackageManager pm = context.getPackageManager(); in isRttSupported() local
40 return pm.hasSystemFeature(PackageManager.FEATURE_WIFI_RTT); in isRttSupported()
44 final PackageManager pm = context.getPackageManager(); in isAwareSupported() local
45 return pm.hasSystemFeature(PackageManager.FEATURE_WIFI_AWARE); in isAwareSupported()
/cts/tests/app/WallpaperTest/src/android/app/cts/wallpapers/
DWallpaperInfoTest.java25 import android.content.pm.PackageManager;
26 import android.content.pm.ResolveInfo;
45 PackageManager pm = context.getPackageManager(); in test_wallpaperServiceQuery() local
47 List<ResolveInfo> result = pm.queryIntentServices(intent, PackageManager.GET_META_DATA); in test_wallpaperServiceQuery()
54 PackageManager pm = context.getPackageManager(); in test_wallpaperInfoOptions() local
59 .isEqualTo(wallpaperInfo.loadLabel(pm)); in test_wallpaperInfoOptions()
61 .isEqualTo(wallpaperInfo.loadDescription(pm)); in test_wallpaperInfoOptions()
63 .isEqualTo(wallpaperInfo.loadAuthor(pm)); in test_wallpaperInfoOptions()
65 .isEqualTo(wallpaperInfo.loadContextDescription(pm)); in test_wallpaperInfoOptions()
67 .isEqualTo(wallpaperInfo.loadContextUri(pm).toString()); in test_wallpaperInfoOptions()
[all …]
/cts/tests/tests/textclassifier/src/android/view/textclassifier/cts/
DTextClassifierPolicyTest.java5 import android.content.pm.PackageManager;
18 PackageManager pm = ApplicationProvider.getApplicationContext().getPackageManager(); in isDefaultTextClassifierPackageKnown() local
19 String defaultTextClassifierPackageName = pm.getDefaultTextClassifierPackageName(); in isDefaultTextClassifierPackageKnown()
20 String extensionServicesPackageName = pm.getServicesSystemSharedLibraryPackageName(); in isDefaultTextClassifierPackageKnown()
31 PackageManager pm = ApplicationProvider.getApplicationContext().getPackageManager(); in defaultTextClassifierIsNotTheSameAsSystemTextClassifier() local
32 String defaultTextClassifierPackageName = pm.getDefaultTextClassifierPackageName(); in defaultTextClassifierIsNotTheSameAsSystemTextClassifier()
33 String systemTextClassifierPackageName = pm.getSystemTextClassifierPackageName(); in defaultTextClassifierIsNotTheSameAsSystemTextClassifier()
/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/mainline/
DModuleDetector.java18 import android.content.pm.PackageInfo;
19 import android.content.pm.PackageManager;
50 public static boolean moduleIsPlayManaged(PackageManager pm, MainlineModule module) in moduleIsPlayManaged() argument
52 return getPlayManagedModules(pm).contains(module); in moduleIsPlayManaged()
59 public static Set<MainlineModule> getPlayManagedModules(PackageManager pm) throws Exception { in getPlayManagedModules() argument
63 for (PackageInfo info : pm.getInstalledPackages(0)) { in getPlayManagedModules()
66 for (PackageInfo info : pm.getInstalledPackages(PackageManager.MATCH_APEX)) { in getPlayManagedModules()
72 && module.certSHA256.equals(getSignatureDigest(pm, module))) { in getPlayManagedModules()
79 private static String getSignatureDigest(PackageManager pm, MainlineModule module) in getSignatureDigest() argument
86 PackageInfo packageInfo = pm.getPackageInfo(module.packageName, flag); in getSignatureDigest()
/cts/tests/appcloning/src/android/appcloning/cts/
DCrossProfileIntentFilterTest.java26 import android.content.pm.PackageManager;
109 PackageManager pm = mPackageManager; in isHardwareSupported() local
110 return !pm.hasSystemFeature(pm.FEATURE_EMBEDDED) in isHardwareSupported()
111 && !pm.hasSystemFeature(pm.FEATURE_WATCH) in isHardwareSupported()
112 && !pm.hasSystemFeature(pm.FEATURE_LEANBACK) in isHardwareSupported()
113 && !pm.hasSystemFeature(pm.FEATURE_AUTOMOTIVE); in isHardwareSupported()
/cts/tests/tests/shortcutmanager/src/android/content/pm/cts/shortcutmanager/
DShortcutManagerSpoofingTest.java16 package android.content.pm.cts.shortcutmanager;
18 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.assertCallbackNotR…
19 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.assertCallbackRece…
20 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.assertWith;
21 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.checkAssertSuccess;
22 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.dumpsysShortcut;
23 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.list;
24 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.resetAll;
25 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.setDefaultLauncher;
26 import static com.android.server.pm.shortcutmanagertest.ShortcutManagerTestUtils.waitUntil;
[all …]
/cts/hostsidetests/appsecurity/test-apps/PrivilegedUpdateApp/src/com/android/cts/privilegedupdate/
DPrivilegedAppDisableTest.java23 import android.content.pm.ApplicationInfo;
24 import android.content.pm.PackageManager;
25 import android.content.pm.ResolveInfo;
26 import android.content.pm.PackageManager.NameNotFoundException;
64 PackageManager pm = getInstrumentation().getContext().getPackageManager(); in getApplicationFlags() local
66 ApplicationInfo aInfo = pm.getApplicationInfo(PRIVILEGED_SHIM_PKG, in getApplicationFlags()
75 PackageManager pm = getInstrumentation().getContext().getPackageManager(); in assertPackageEnabledState() local
76 int state = pm.getApplicationEnabledSetting(packageName); in assertPackageEnabledState()
/cts/hostsidetests/statsdatom/apps/statsdapp/src/com/android/server/cts/device/statsdatom/
DCheckers.java22 import android.content.pm.PackageInfo;
23 import android.content.pm.PackageManager;
54 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in checkValidLightSensor() local
55 assertThat(pm.hasSystemFeature(PackageManager.FEATURE_SENSOR_LIGHT)).isTrue(); in checkValidLightSensor()
60 PackageManager pm = InstrumentationRegistry.getContext().getPackageManager(); in checkBrightnessSliderPermission() local
63 Manifest.permission.BRIGHTNESS_SLIDER_USAGE, pm)).isGreaterThan(0); in checkBrightnessSliderPermission()
77 private int numberOfSystemAppsWithPermission(String permission, PackageManager pm) { in numberOfSystemAppsWithPermission() argument
78 List<PackageInfo> packages = pm.getPackagesHoldingPermissions( in numberOfSystemAppsWithPermission()
/cts/tests/tests/packageinstaller/install/src/android/packageinstaller/install/cts/
DUpdateOwnershipEnforcementMultiUserTest.kt20 import android.content.pm.PackageManager
69 var sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithoutRequestingUpdateOwnership_hasNoUpdateOwner()
73 sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithoutRequestingUpdateOwnership_hasNoUpdateOwner()
87 var sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithRequestingUpdateOwnership_updateOwnerIsTheSame_ownerRetained()
93 sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithRequestingUpdateOwnership_updateOwnerIsTheSame_ownerRetained()
107 var sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithRequestingUpdateOwnership_updateOwnerIsNotTheSame_hasNoUpdateOwner()
113 sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithRequestingUpdateOwnership_updateOwnerIsNotTheSame_hasNoUpdateOwner()
125 var sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithRequestingUpdateOwnership_noUpdateOwnerIsSet_hasNoUpdateOwner()
131 sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installWithRequestingUpdateOwnership_noUpdateOwnerIsSet_hasNoUpdateOwner()
149 var sourceInfo = pm.getInstallSourceInfo(TEST_APK_PACKAGE_NAME) in installExistingPackage_updateOwnerIsNotTheSame_hasNoUpdateOwner()
[all …]
/cts/common/device-side/bedstead/remoteframeworkclasses/java/apis/
Dtype-blocklist.txt30 android.content.pm.ArchivedPackageInfo
31 android.content.pm.LauncherActivityInfo
32 android.content.pm.LauncherApps.ArchiveCompatibilityParams
33 android.content.pm.LauncherApps.Callback
34 android.content.pm.LauncherApps.ShortcutQuery
35 android.content.pm.PackageInstaller
36 android.content.pm.PackageInstaller.SessionCallback
37 android.content.pm.PackageManager
38 android.content.pm.PackageManager.ApplicationInfoFlags
39 android.content.pm.PackageManager.ComponentInfoFlags
[all …]
/cts/tests/PhotoPicker/src/android/photopicker/cts/
DPhotoPickerBaseTest.java24 import android.content.pm.PackageManager;
84 PackageManager pm = sInstrumentation.getContext().getPackageManager(); in isHardwareSupported() local
85 return !pm.hasSystemFeature(pm.FEATURE_EMBEDDED) in isHardwareSupported()
86 && !pm.hasSystemFeature(pm.FEATURE_WATCH) in isHardwareSupported()
87 && !pm.hasSystemFeature(pm.FEATURE_LEANBACK); in isHardwareSupported()
/cts/tests/tests/security/src/android/security/cts/
DVerifiedBootTest.java24 import android.content.pm.PackageManager;
56 private static boolean isLowRamExempt(PackageManager pm) { in isLowRamExempt() argument
57 if (pm.hasSystemFeature(PackageManager.FEATURE_RAM_NORMAL)) { in isLowRamExempt()
77 PackageManager pm = mContext.getPackageManager(); in testVerifiedBootSupport() local
78 assertNotNull("PackageManager must not be null", pm); in testVerifiedBootSupport()
79 if (isLowRamExempt(pm)) { in testVerifiedBootSupport()
83 pm.hasSystemFeature(PackageManager.FEATURE_VERIFIED_BOOT)); in testVerifiedBootSupport()
/cts/hostsidetests/securitybulletin/test-apps/CVE-2021-0921/src/android/security/cts/CVE_2021_0921/
DTrigger.java7 import android.content.pm.ApplicationInfo;
8 import android.content.pm.PackageManager;
23 PackageManager pm = context.getPackageManager(); in isCar() local
24 return pm.hasSystemFeature(PackageManager.FEATURE_AUTOMOTIVE); in isCar()
28 PackageManager pm = context.getPackageManager(); in isWear() local
29 return pm.hasSystemFeature(PackageManager.FEATURE_WATCH); in isWear()
33 PackageManager pm = context.getPackageManager(); in isTv() local
34 return pm.hasSystemFeature(PackageManager.FEATURE_TELEVISION); in isTv()

12345678910>>...58