/packages/modules/Permission/tests/cts/permission/src/android/permission/cts/ |
D | NearbyDevicesPermissionTest.java | 23 import static android.permission.cts.PermissionUtils.grantPermission; 123 grantPermission(TEST_APP_PKG, ACCESS_FINE_LOCATION); in testRequestBluetoothPermission30_GrantLocation() 124 grantPermission(TEST_APP_PKG, ACCESS_BACKGROUND_LOCATION); in testRequestBluetoothPermission30_GrantLocation() 141 grantPermission(TEST_APP_PKG, BLUETOOTH_CONNECT); in testRequestBluetoothPermission31_GrantNearby() 142 grantPermission(TEST_APP_PKG, BLUETOOTH_SCAN); in testRequestBluetoothPermission31_GrantNearby() 150 grantPermission(TEST_APP_PKG, ACCESS_FINE_LOCATION); in testRequestBluetoothPermission31_GrantLocation() 151 grantPermission(TEST_APP_PKG, ACCESS_BACKGROUND_LOCATION); in testRequestBluetoothPermission31_GrantLocation() 161 grantPermission(TEST_APP_PKG, BLUETOOTH_CONNECT); in testRequestBluetoothPermission31_GrantNearby_GrantLocation() 162 grantPermission(TEST_APP_PKG, BLUETOOTH_SCAN); in testRequestBluetoothPermission31_GrantNearby_GrantLocation() 163 grantPermission(TEST_APP_PKG, ACCESS_FINE_LOCATION); in testRequestBluetoothPermission31_GrantNearby_GrantLocation() [all …]
|
D | SplitPermissionTest.java | 29 import static android.permission.cts.PermissionUtils.grantPermission; 274 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in inheritGrantedPermissionState() 290 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in inheritGrantedPermissionStateSharedUidApp() 401 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in grantNewSplitPermissionState() 402 grantPermission(APP_PKG, ACCESS_BACKGROUND_LOCATION); in grantNewSplitPermissionState() 421 grantPermission(APP_PKG, READ_CALL_LOG); in grantNewSplitPermissionStatePreM() 434 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in revokeNewSplitPermissionState() 435 grantPermission(APP_PKG, ACCESS_BACKGROUND_LOCATION); in revokeNewSplitPermissionState() 465 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in newPermissionGetRevokedOnUpgrade() 466 grantPermission(APP_PKG, ACCESS_BACKGROUND_LOCATION); in newPermissionGetRevokedOnUpgrade() [all …]
|
D | SharedUidPermissionsTest.java | 21 import static android.permission.cts.PermissionUtils.grantPermission; 68 grantPermission(PKG_THAT_REQUESTS_PERMISSIONS, READ_CONTACTS); in packageGainsRuntimePermissionsWhenJoiningSharedUid() 88 grantPermission(PKG_THAT_REQUESTS_PERMISSIONS, READ_CONTACTS); in grantingRuntimePermissionAffectsAllPackageInSharedUid() 98 grantPermission(PKG_THAT_REQUESTS_PERMISSIONS, READ_CONTACTS); in revokingRuntimePermissionAffectsAllPackageInSharedUid() 110 grantPermission(PKG_THAT_REQUESTS_PERMISSIONS, READ_CONTACTS); in runtimePermissionsCanBeRevokedOnPackageThatDoesNotDeclarePermission() 123 grantPermission(PKG_THAT_REQUESTS_NO_PERMISSIONS, READ_CONTACTS); in runtimePermissionsCanBeGrantedOnPackageThatDoesNotDeclarePermission() 134 grantPermission(PKG_THAT_REQUESTS_PERMISSIONS, READ_CONTACTS); in sharedUidLoosesRuntimePermissionWhenLastAppDeclaringItGetsUninstalled()
|
D | RevokeSelfPermissionTest.java | 30 import static android.permission.cts.PermissionUtils.grantPermission; 128 grantPermission(APP_PKG_NAME, permission); in testMultiplePermissions() 161 grantPermission(APP_PKG_NAME, ACCESS_FINE_LOCATION); in testKillTriggersRevocation() 174 grantPermission(APP_PKG_NAME, ACCESS_FINE_LOCATION); in testNoRevocationWhileForeground() 195 grantPermission(APP_PKG_NAME, ACCESS_COARSE_LOCATION); in testRevokeLocationPermission() 197 grantPermission(APP_PKG_NAME, ACCESS_FINE_LOCATION); in testRevokeLocationPermission() 199 grantPermission(APP_PKG_NAME, ACCESS_BACKGROUND_LOCATION); in testRevokeLocationPermission() 209 grantPermission(APP_PKG_NAME, ACCESS_BACKGROUND_LOCATION); in testRevokeLocationPermission() 234 grantPermission(APP_PKG_NAME, ACCESS_FINE_LOCATION); in testNoRepromptWhenUserFixed()
|
D | RemovePermissionTest.java | 153 private void grantPermission(String pkg, String permission) { in grantPermission() method in RemovePermissionTest 164 grantPermission(ADVERSARIAL_PERMISSION_USER_PKG_NAME, TEST_PERMISSION); in runtimePermissionShouldBeRevokedIfRemoved() 179 grantPermission(RUNTIME_PERMISSION_USER_PKG_NAME, TEST_RUNTIME_PERMISSION); in runtimePermissionShouldRemainGrantedAfterAppUpdate() 193 grantPermission(ADVERSARIAL_PERMISSION_USER_PKG_NAME, TEST_PERMISSION); in runtimePermissionDependencyTest() 200 grantPermission(ADVERSARIAL_PERMISSION_USER_PKG_NAME, TEST_PERMISSION); in runtimePermissionDependencyTest()
|
D | PermissionControllerTest.java | 34 import static android.permission.cts.PermissionUtils.grantPermission; 409 PermissionUtils.grantPermission(APP2, BODY_SENSORS); in getAppPermissionsForCustomApp() 410 PermissionUtils.grantPermission(APP2, READ_CONTACTS); in getAppPermissionsForCustomApp() 411 PermissionUtils.grantPermission(APP2, WRITE_CALENDAR); in getAppPermissionsForCustomApp() 432 grantPermission(APP2, READ_CALENDAR); in revokePermissionAutomaticallyExtendsToWholeGroup() 433 grantPermission(APP2, WRITE_CALENDAR); in revokePermissionAutomaticallyExtendsToWholeGroup()
|
D | BackgroundPermissionsTest.java | 28 import static android.permission.cts.PermissionUtils.grantPermission; 129 grantPermission(APP_PKG, ACCESS_COARSE_LOCATION); in appOpGetsDowngradedWhenBgPermIsNotRequestedAnymore()
|
/packages/modules/Permission/tests/cts/permissionui/src/android/permissionui/cts/ |
D | NotificationPermissionTest.kt | 263 val grantPermission = Intent(PackageManager.ACTION_REQUEST_PERMISSIONS_FOR_OTHER) in nonSystemServerPackageCannotShowPromptForOtherPackage() constant 264 grantPermission.putExtra(Intent.EXTRA_PACKAGE_NAME, APP_PACKAGE_NAME) in nonSystemServerPackageCannotShowPromptForOtherPackage() 265 grantPermission.putExtra( in nonSystemServerPackageCannotShowPromptForOtherPackage() 269 grantPermission.setPackage(context.packageManager.permissionControllerPackageName) in nonSystemServerPackageCannotShowPromptForOtherPackage() 270 grantPermission.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) in nonSystemServerPackageCannotShowPromptForOtherPackage() 271 context.startActivity(grantPermission) in nonSystemServerPackageCannotShowPromptForOtherPackage()
|
/packages/modules/Permission/PermissionController/tests/permissionui/src/com/android/permissioncontroller/permissionui/ui/handheld/ |
D | ManageCustomPermissionsFragmentTest.kt | 20 import android.permission.cts.PermissionUtils.grantPermission 73 grantPermission(USER_PKG, PERM) in groupSummaryGetsUpdatedWhenPermissionGetsGranted() 88 grantPermission(USER_PKG, PERM) in groupSummaryGetsUpdatedWhenPermissionGetsRevoked()
|
D | ManageStandardPermissionsFragmentTest.kt | 22 import android.permission.cts.PermissionUtils.grantPermission 153 grantPermission(LOCATION_USER_PKG, ACCESS_COARSE_LOCATION) in groupSummaryGetsUpdatedWhenPermissionGetsGranted() 165 grantPermission(LOCATION_USER_PKG, ACCESS_COARSE_LOCATION) in groupSummaryGetsUpdatedWhenPermissionGetsRevoked()
|
/packages/modules/Permission/PermissionController/tests/permissionui/src/com/android/permissioncontroller/permissionui/ui/ |
D | TestAppUtils.kt | 19 import android.permission.cts.PermissionUtils.grantPermission 73 fun grantTestAppPermission(permission: String) = grantPermission(PERM_USER_PACKAGE, permission)
|
/packages/modules/HealthFitness/tests/integrationtests/src/android/healthconnect/tests/backuprestore/ |
D | BackupRestoreE2ETest.java | 20 import static android.healthconnect.cts.utils.PermissionHelper.grantPermission; 225 grantPermission(TEST_APP_1_PACKAGE_NAME, TEST_APP_DECLARED_PERMISSION); in testPermissionRestoredBeforeHCRestore_expectGrantTimeIsRestoredCorrectly() 243 grantPermission(TEST_APP_1_PACKAGE_NAME, TEST_APP_DECLARED_PERMISSION); in testPermissionRestoredBeforeHCRestore_expectGrantTimeIsRestoredCorrectly() 244 grantPermission(TEST_APP_2_PACKAGE_NAME, TEST_APP_DECLARED_PERMISSION); in testPermissionRestoredBeforeHCRestore_expectGrantTimeIsRestoredCorrectly() 280 grantPermission(TEST_APP_1_PACKAGE_NAME, TEST_APP_DECLARED_PERMISSION); in testPermissionsRestoredAfterHCRestore_expectGrantTimeIsRestoredCorrectly() 306 grantPermission(TEST_APP_1_PACKAGE_NAME, TEST_APP_DECLARED_PERMISSION); in testPermissionsRestoredAfterHCRestore_expectGrantTimeIsRestoredCorrectly()
|
/packages/modules/HealthFitness/tests/cts/hostsidetests/healthconnect/device/src/android/healthconnect/cts/device/ |
D | HealthConnectDeviceTest.java | 36 import static android.healthconnect.cts.utils.PermissionHelper.grantPermission; 179 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), APP_A_DECLARED_PERMISSION); in setUp() 186 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), APP_A_DECLARED_PERMISSION); in tearDown() 705 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), perm); in testGrantingCorrectPermsPutsTheAppInPriorityList() 731 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), perm); in testRevokingOnlyOneCorrectPermissionDoesntRemoveAppFromPriorityList() 756 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), healthPerms.get(0)); in testRevokingOnlyOneCorrectPermissionDoesntRemoveAppFromPriorityList() 770 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), perm); in testRevokingAllCorrectPermissionsRemovesAppFromPriorityList() 799 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), perm); in testRevokingAllCorrectPermissionsRemovesAppFromPriorityList() 805 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), APP_A_DECLARED_PERMISSION); in testSelfRevokePermissions_revokedOnKill() 834 grantPermission(APP_A_WITH_READ_WRITE_PERMS.getPackageName(), perm); in testAppWithManageHealthDataPermissionCanUpdatePriority() [all …]
|
/packages/modules/Permission/PermissionController/tests/permissionui/src/com/android/permissioncontroller/permissionui/ui/handheld/v31/ |
D | PermissionUsageFragmentTest.kt | 22 import android.permission.cts.PermissionUtils.grantPermission 52 grantPermission(APP, CAMERA) in setup()
|
/packages/modules/Virtualization/service_vm/test_apk/src/java/com/android/virt/vm_attestation/testapp/ |
D | VmAttestationTests.java | 60 grantPermission(VirtualMachine.MANAGE_VIRTUAL_MACHINE_PERMISSION); in setup() 61 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in setup()
|
/packages/modules/HealthFitness/tests/cts/utils/HealthConnectTestUtils/src/android/healthconnect/cts/utils/ |
D | PermissionHelper.java | 108 public static void grantPermission(String pkgName, String permission) { in grantPermission() method in PermissionHelper 121 grantPermission(pkgName, permission); in grantPermissions() 170 grantPermission(packageName, perm); in revokeAndThenGrantHealthPermissions()
|
/packages/modules/HealthFitness/tests/cts/src/android/healthconnect/cts/ui/ |
D | ExerciseRouteRequestTest.kt | 36 import android.healthconnect.cts.utils.PermissionHelper.grantPermission 222 grantPermission(ROUTE_READER_WRITER_APP.getPackageName(), READ_EXERCISE_ROUTES) in requestRoute_ownSession_writeRouteDenied_readRoutesGranted_returnsRoute() 245 grantPermission(ROUTE_READER_WRITER_APP.getPackageName(), READ_EXERCISE_ROUTES) in requestRoute_readRoutesGranted_doesNotShowDialog_returnsRoute() 329 grantPermission(ROUTE_READER_WRITER_APP.getPackageName(), READ_EXERCISE_ROUTES) in requestRoute_readExercisePermissionRevoked_throwsSecurityException()
|
/packages/modules/Virtualization/tests/testapk/src/java/com/android/microdroid/test/ |
D | MicrodroidTests.java | 155 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in setup() 1015 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in extraApk() 1041 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in extraApkInVmConfig() 1240 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in instancesOfSameVmHaveDifferentCdis() 1266 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in sameInstanceKeepsSameCdis() 1286 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in bccIsSuperficiallyWellFormed() 1436 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in bootFailsWhenConfigIsInvalid() 1561 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in importedVmAndOriginalVmHaveTheSameCdi() 2337 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in buildVmConfigWithNetworkSupported() 2386 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in buildVmConfigWithVendor()
|
/packages/modules/HealthFitness/apk/src/com/android/healthconnect/controller/permissions/app/ |
D | AppPermissionViewModel.kt | 208 grantPermission(packageName, dataTypePermission) in <lambda>() 224 private fun grantPermission(packageName: String, fitnessPermission: FitnessPermission) { in <lambda>() method
|
/packages/services/Car/car-usb-handler/src/android/car/usb/handler/ |
D | UsbUtil.java | 50 manager.grantPermission(device); in openConnection()
|
/packages/modules/Virtualization/service_vm/test_apk/src/java/com/android/virt/rkpd/vm_attestation/testapp/ |
D | RkpdVmAttestationTest.java | 102 grantPermission(VirtualMachine.USE_CUSTOM_VIRTUAL_MACHINE_PERMISSION); in setUp()
|
/packages/modules/HealthFitness/tests/cts/src/android/healthconnect/cts/nopermission/ |
D | HealthConnectManagerNoPermissionsGrantedTest.java | 40 import static android.healthconnect.cts.utils.PermissionHelper.grantPermission; 198 grantPermission(packageName, permission); in testGetChangeLogs_noPermissions_expectError()
|
/packages/services/Telephony/tests/src/com/android/ |
D | TestContext.java | 261 public void grantPermission(String permission) { in grantPermission() method in TestContext
|
/packages/services/Mtp/src/com/android/mtp/ |
D | MtpManager.java | 89 mManager.grantPermission(rawDevice); in openDevice()
|
/packages/modules/Permission/tests/cts/permission/permissionTestUtilLib/src/android/permission/cts/ |
D | PermissionUtils.java | 204 public static void grantPermission(@NonNull String packageName, @NonNull String permission) in grantPermission() method in PermissionUtils
|