/cts/tests/tests/permission/src/android/permission/cts/ |
D | PermissionFlagsTest.java | 56 private static final String APP_PKG = "android.permission.cts.appthatrequestpermission"; field in PermissionFlagsTest 68 uninstallApp(APP_PKG); in uninstallTestApp() 76 getPermissionFlags(APP_PKG, ACCESS_BACKGROUND_LOCATION)); in implicitPermission() 83 assertEquals(0, getPermissionFlags(APP_PKG, ACCESS_COARSE_LOCATION)); in regularPermission() 91 getPermissionFlags(APP_PKG, READ_CONTACTS)); in regularPermissionPreM() 99 FLAG_PERMISSION_REVOKE_WHEN_REQUESTED, getPermissionFlags(APP_PKG, READ_CALL_LOG)); in implicitPermissionPreM() 106 int defaultState = getPermissionFlags(APP_PKG, READ_CONTACTS); in clearRegularPermissionPreM() 107 setPermissionFlags(APP_PKG, READ_CONTACTS, FLAG_PERMISSION_REVIEW_REQUIRED, 0); in clearRegularPermissionPreM() 108 setPermissionFlags(APP_PKG, READ_CONTACTS, in clearRegularPermissionPreM() 112 clearAppState(APP_PKG); in clearRegularPermissionPreM() [all …]
|
D | SplitPermissionTest.java | 68 private static final String APP_PKG = "android.permission.cts.appthatrequestpermission"; field in SplitPermissionTest 105 assertThat(getPermissions(APP_PKG)).contains(permName); in assertRequestsPermission() 114 assertThat(getPermissions(APP_PKG)).doesNotContain(permName); in assertNotRequestsPermission() 124 isGranted(APP_PKG, permName)).isTrue()); in assertPermissionGranted() 133 assertWithMessage(permName + " is granted").that(isGranted(APP_PKG, permName)).isFalse(); in assertPermissionRevoked() 147 uninstallApp(APP_PKG); in uninstallTestApp() 264 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in inheritGrantedPermissionState() 280 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in inheritGrantedPermissionStateSharedUidApp() 297 setPermissionFlags(APP_PKG, READ_CONTACTS, FLAG_PERMISSION_USER_SET, in inheritFlagsPreM() 303 getPermissionFlags(APP_PKG, READ_CALL_LOG) & FLAG_PERMISSION_USER_SET); in inheritFlagsPreM() [all …]
|
D | BackgroundPermissionsTest.java | 62 private static final String APP_PKG = "android.permission.cts.appthatrequestpermission"; field in BackgroundPermissionsTest 77 uninstallApp(APP_PKG); in uninstallTestApp() 129 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in appOpGetsDowngradedWhenBgPermIsNotRequestedAnymore() 134 getAppOp(APP_PKG, ACCESS_COARSE_LOCATION)).isEqualTo(MODE_FOREGROUND)); in appOpGetsDowngradedWhenBgPermIsNotRequestedAnymore() 149 getAppOp(APP_PKG, ACCESS_COARSE_LOCATION)).isEqualTo(MODE_IGNORED)); in appOpIsSetIfNoLocPermIsGranted() 161 sUiAutomation.grantRuntimePermission(APP_PKG, ACCESS_COARSE_LOCATION); in appOpIsSetIfOnlyCoarseLocPermIsGranted() 165 getAppOp(APP_PKG, ACCESS_COARSE_LOCATION)).isEqualTo(MODE_FOREGROUND)); in appOpIsSetIfOnlyCoarseLocPermIsGranted() 177 sUiAutomation.grantRuntimePermission(APP_PKG, ACCESS_COARSE_LOCATION); in appOpIsSetIfCoarseAndBgLocPermIsGranted() 178 sUiAutomation.grantRuntimePermission(APP_PKG, ACCESS_BACKGROUND_LOCATION); in appOpIsSetIfCoarseAndBgLocPermIsGranted() 182 getAppOp(APP_PKG, ACCESS_COARSE_LOCATION)).isEqualTo(MODE_ALLOWED)); in appOpIsSetIfCoarseAndBgLocPermIsGranted() [all …]
|
/cts/tests/tests/appop/src/android/app/appops/cts/ |
D | RuntimeMessageCollectionTest.kt | 30 private const val APP_PKG = "android.app.appops.cts.apptocollect" constant 43 appUid = context.packageManager.getPackageUid(APP_PKG, 0) in installApk() 48 runCommand("pm uninstall $APP_PKG") in resetTestApp() 58 appOpsManager.noteOp(AppOpsManager.OPSTR_READ_CONTACTS, appUid, APP_PKG, in collectAsyncStackTrace() 66 if (message != null && message.packageName.equals(APP_PKG)) { in collectAsyncStackTrace()
|
D | AttributionTest.kt | 35 private const val APP_PKG = "android.app.appops.cts.apptoblame" constant 51 private val appUid by lazy { context.packageManager.getPackageUid(APP_PKG, 0) } in <lambda>() 60 runCommand("pm uninstall $APP_PKG") in resetTestApp() 69 appOpsManager.noteOp(OPSTR_WIFI_SCAN, appUid, APP_PKG, attribution, null) in noteForAttribution() 122 val beforeUpdate = getOpEntry(appUid, APP_PKG, OPSTR_WIFI_SCAN)!! in inheritNotedAppOpsOnUpgrade() 126 val afterUpdate = getOpEntry(appUid, APP_PKG, OPSTR_WIFI_SCAN)!! in inheritNotedAppOpsOnUpgrade() 158 val opEntry = getOpEntry(appUid, APP_PKG, OPSTR_WIFI_SCAN)!! in canUseUndeclaredAttributionTagButTreatedAsNull()
|
/cts/hostsidetests/car/src/android/car/cts/ |
D | PreCreateUsersHostTest.java | 55 getDevice().uninstallPackage(APP_PKG); in uninstallPackage() 106 assertAppInstalledForUser(APP_PKG, initialUserId); in appsAreNotInstalledOnPreCreatedUserTest() 107 assertAppNotInstalledForUser(APP_PKG, preCreatedUserId); in appsAreNotInstalledOnPreCreatedUserTest() 113 assertAppInstalledForUser(APP_PKG, initialUserId); in appsAreNotInstalledOnPreCreatedUserTest() 114 assertAppNotInstalledForUser(APP_PKG, preCreatedUserId); in appsAreNotInstalledOnPreCreatedUserTest() 117 assertAppNotInstalledForUser(APP_PKG, preCreatedUserId); in appsAreNotInstalledOnPreCreatedUserTest()
|
D | CarHostJUnit4TestCase.java | 82 protected static final String APP_PKG = "android.car.cts.app"; field in CarHostJUnit4TestCase
|