/cts/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/ |
D | DeviceOwnerPlusProfileOwnerTest.java | 70 installAppAsUser(COMP_DPC_APK, mPrimaryUserId); in setUp() 71 if (!setDeviceOwner(COMP_DPC_ADMIN, mPrimaryUserId, /*expectFailure*/ false)) { in setUp() 72 removeAdmin(COMP_DPC_ADMIN, mPrimaryUserId); in setUp() 79 mPrimaryUserId); in setUp() 87 removeAdmin(COMP_DPC_ADMIN, mPrimaryUserId)); in tearDown() 165 mPrimaryUserId); in testBindDeviceAdminServiceAsUser_byodPlusDeviceOwnerCannotBind() 183 installAppAsUser(COMP_DPC_APK2, mPrimaryUserId); in testBindDeviceAdminServiceAsUser_secondaryUser() 269 mPrimaryUserId); in testDoCanRemoveProfileEvenIfUserRestrictionSet() 278 assertCannotCreateManagedProfile(mPrimaryUserId); in testCannotAddProfileIfRestrictionSet() 288 installAppAsUser(COMP_DPC_APK2, mPrimaryUserId); in testIsProvisioningAllowed() [all …]
|
D | CustomDeviceOwnerTest.java | 60 installAppAsUser(DEVICE_OWNER_APK, mPrimaryUserId); in testOwnerChangedBroadcast() 62 installAppAsUser(INTENT_RECEIVER_APK, mPrimaryUserId); in testOwnerChangedBroadcast() 69 "testOwnerChangedBroadcastNotReceived", mPrimaryUserId); in testOwnerChangedBroadcast() 72 assertTrue(setDeviceOwner(DEVICE_OWNER_ADMIN_COMPONENT, mPrimaryUserId, in testOwnerChangedBroadcast() 79 "testOwnerChangedBroadcastReceived", mPrimaryUserId); in testOwnerChangedBroadcast() 83 removeAdmin(DEVICE_OWNER_ADMIN_COMPONENT, mPrimaryUserId)); in testOwnerChangedBroadcast() 92 installAppAsUser(DEVICE_OWNER_APK, mPrimaryUserId); in testCannotSetDeviceOwnerWhenSecondaryUserPresent() 95 assertFalse(setDeviceOwner(DEVICE_OWNER_ADMIN_COMPONENT, mPrimaryUserId, in testCannotSetDeviceOwnerWhenSecondaryUserPresent() 100 removeAdmin(DEVICE_OWNER_ADMIN_COMPONENT, mPrimaryUserId); in testCannotSetDeviceOwnerWhenSecondaryUserPresent() 108 installAppAsUser(ACCOUNT_MANAGEMENT_APK, mPrimaryUserId); in testCannotSetDeviceOwnerWhenAccountPresent() [all …]
|
D | AccountCheckHostSideTest.java | 70 assertTrue(removeAdmin(OWNER_TEST_ONLY, mPrimaryUserId)); in runCleanupTestOnlyOwner() 103 setDeviceOwnerOrFail(OWNER_TEST_ONLY, mPrimaryUserId); in assertTestOnlyInstallable() 106 setProfileOwnerOrFail(OWNER_TEST_ONLY, mPrimaryUserId); in assertTestOnlyInstallable() 111 setDeviceOwnerOrFail(OWNER_NON_TEST_ONLY, mPrimaryUserId); in assertNonTestOnlyInstallable() 114 setProfileOwnerOrFail(OWNER_NON_TEST_ONLY, mPrimaryUserId); in assertNonTestOnlyInstallable() 119 setDeviceOwnerExpectingFailure(OWNER_TEST_ONLY, mPrimaryUserId); in assertTestOnlyNotInstallable() 122 setProfileOwnerExpectingFailure(OWNER_TEST_ONLY, mPrimaryUserId); in assertTestOnlyNotInstallable() 127 setDeviceOwnerExpectingFailure(OWNER_NON_TEST_ONLY, mPrimaryUserId); in assertNonTestOnlyNotInstallable() 130 setProfileOwnerExpectingFailure(OWNER_NON_TEST_ONLY, mPrimaryUserId); in assertNonTestOnlyNotInstallable() 154 installAppAsUser(APK_AUTH, mPrimaryUserId); in testAccountCheck() [all …]
|
D | DeviceOwnerTest.java | 107 installAppAsUser(DEVICE_OWNER_APK, mPrimaryUserId); in setUp() 108 if (!setDeviceOwner(DEVICE_OWNER_COMPONENT, mPrimaryUserId, in setUp() 110 removeAdmin(DEVICE_OWNER_COMPONENT, mPrimaryUserId); in setUp() 127 removeAdmin(DEVICE_OWNER_COMPONENT, mPrimaryUserId)); in tearDown() 622 installAppAsUser(WIFI_CONFIG_CREATOR_APK, mPrimaryUserId); in testWifiConfigLockdown() 648 DEVICE_OWNER_PKG + "/" + ADMIN_RECEIVER_TEST_CLASS, mPrimaryUserId, in testCannotSetDeviceOwnerAgain() 653 installAppAsUser(MANAGED_PROFILE_APK, mPrimaryUserId); in testCannotSetDeviceOwnerAgain() 655 MANAGED_PROFILE_PKG + "/" + MANAGED_PROFILE_ADMIN, mPrimaryUserId, in testCannotSetDeviceOwnerAgain() 659 removeAdmin(MANAGED_PROFILE_PKG + "/" + MANAGED_PROFILE_ADMIN, mPrimaryUserId); in testCannotSetDeviceOwnerAgain() 751 changeUserRestrictionOrFail("no_factory_reset", true, mPrimaryUserId, in testDisallowFactoryReset() [all …]
|
D | CrossProfileAppsHostSideTest.java | 39 installRequiredApps(mPrimaryUserId); in setUp() 61 verifyCrossProfileAppsApi(mPrimaryUserId, mPrimaryUserId, NON_TARGET_USER_TEST_CLASS); in testPrimaryUserToPrimaryUser() 68 verifyCrossProfileAppsApi(mPrimaryUserId, mProfileId, TARGET_USER_TEST_CLASS); in testPrimaryUserToManagedProfile() 75 verifyCrossProfileAppsApi(mProfileId, mPrimaryUserId, TARGET_USER_TEST_CLASS); in testManagedProfileToPrimaryUser() 82 verifyCrossProfileAppsApi(mProfileId, mPrimaryUserId, START_ACTIVITY_TEST_CLASS); in testStartActivity() 89 verifyCrossProfileAppsApi(mPrimaryUserId, mSecondaryUserId, NON_TARGET_USER_TEST_CLASS); in testPrimaryUserToSecondaryUser() 116 mPrimaryUserId, in testStartMainActivity_logged() 135 mPrimaryUserId, in testGetTargetUserProfiles_logged() 162 mProfileId = createManagedProfile(mPrimaryUserId); in createAndStartManagedProfile() 163 switchUser(mPrimaryUserId); in createAndStartManagedProfile()
|
D | QuietModeHostsideTest.java | 32 installAppAsUser(TEST_APK, mPrimaryUserId); in setUp() 33 installAppAsUser(TEST_LAUNCHER_APK, mPrimaryUserId); in setUp() 60 mPrimaryUserId, in testQuietMode_defaultForegroundLauncher() 72 mPrimaryUserId, in testQuietMode_notForegroundLauncher() 84 mPrimaryUserId, in testQuietMode_notDefaultLauncher() 89 mProfileId = createManagedProfile(mPrimaryUserId); in createAndStartManagedProfile() 90 switchUser(mPrimaryUserId); in createAndStartManagedProfile()
|
D | LauncherAppsMultiUserTest.java | 46 installTestApps(mPrimaryUserId); in setUp() 67 installAppAsUser(SIMPLE_APP_APK, mPrimaryUserId); in testGetActivitiesForNonProfileFails() 71 mPrimaryUserId, in testGetActivitiesForNonProfileFails() 79 startCallbackService(mPrimaryUserId); in testNoLauncherCallbackPackageAddedSecondaryUser() 80 installAppAsUser(SIMPLE_APP_APK, mPrimaryUserId); in testNoLauncherCallbackPackageAddedSecondaryUser() 84 mPrimaryUserId, in testNoLauncherCallbackPackageAddedSecondaryUser()
|
D | DeviceAndProfileOwnerHostSideTransferTest.java | 43 final boolean hasManagedProfile = (mUserId != mPrimaryUserId); in testTransferOwnership() 183 final int userId = createManagedProfile(mPrimaryUserId); in setupManagedProfile() 203 mPrimaryUserId); in clearDisallowAddManagedProfileRestriction() 214 mPrimaryUserId); in addDisallowAddManagedProfileRestriction() 237 "testSetAffiliationId1", mPrimaryUserId); in setSameAffiliationId() 247 "testIsAffiliationId1", mPrimaryUserId); in assertAffiliationIdsAreIntact()
|
D | MixedDeviceOwnerHostSideTransferTest.java | 38 installAppAsUser(TRANSFER_OWNER_OUTGOING_APK, mPrimaryUserId); in setUp() 39 if (setDeviceOwner(TRANSFER_OWNER_OUTGOING_TEST_RECEIVER, mPrimaryUserId, in setUp() 41 setupTestParameters(mPrimaryUserId, TRANSFER_DEVICE_OWNER_OUTGOING_TEST, in setUp()
|
D | AdbProvisioningTests.java | 37 installAppAsUser(DEVICE_ADMIN_APK, mPrimaryUserId); in setUp() 54 setDeviceOwner(DEVICE_ADMIN_PKG + "/" + ADMIN_RECEIVER_TEST_CLASS, mPrimaryUserId, in testAdbDeviceOwnerLogged() 68 setProfileOwner(DEVICE_ADMIN_PKG + "/" + ADMIN_RECEIVER_TEST_CLASS, mPrimaryUserId, in testAdbProfileOwnerLogged()
|
D | LauncherAppsProfileTest.java | 49 mParentUserId = mPrimaryUserId; in setUp() 141 startCallbackService(mPrimaryUserId); in testLauncherCallbackPackageAddedProfile() 154 startCallbackService(mPrimaryUserId); in testLauncherCallbackPackageRemovedProfile() 167 startCallbackService(mPrimaryUserId); in testLauncherCallbackPackageChangedProfile()
|
D | ManagedProfileProvisioningSingleAdminTest.java | 39 installAppAsUser(SINGLE_ADMIN_APP_APK, mPrimaryUserId); in setUp() 61 "testManagedProfileProvisioning", mPrimaryUserId); in testEXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME()
|
D | DevicePlusProfileOwnerHostSideTransferTest.java | 23 installAppAsUser(TRANSFER_OWNER_OUTGOING_APK, mPrimaryUserId); in setUp() 25 if (setDeviceOwner(TRANSFER_OWNER_OUTGOING_TEST_RECEIVER, mPrimaryUserId, in setUp()
|
D | ManagedProfileTest.java | 117 mParentUserId = mPrimaryUserId; in setUp() 291 startDummyActivity(mPrimaryUserId, true); in testWorkProfileTimeoutBackground() 351 runProfileTimeoutTest("testDeviceNotLocked", mPrimaryUserId); in verifyOnlyProfileLocked() 1270 "testBluetoothSharingAvailable", mPrimaryUserId); in testBluetoothSharingRestriction() 1383 changeUserCredential(password, /* oldCredential= */ null, mPrimaryUserId); in testUnlockWorkProfile_deviceWidePassword() 1387 verifyUserCredential(password, mPrimaryUserId); in testUnlockWorkProfile_deviceWidePassword() 1394 changeUserCredential(/* newCredential= */ null, password, mPrimaryUserId); in testUnlockWorkProfile_deviceWidePassword() 1405 changeUserCredential(password, /* oldCredential= */ null, mPrimaryUserId); in testRebootDevice_unifiedPassword() 1408 verifyUserCredential(password, mPrimaryUserId); in testRebootDevice_unifiedPassword() 1413 changeUserCredential(/* newCredential= */ null, password, mPrimaryUserId); in testRebootDevice_unifiedPassword() [all …]
|
D | MixedManagedProfileOwnerTest.java | 41 mParentUserId = mPrimaryUserId; in setUp() 105 mPrimaryUserId); in testScreenCaptureDisabled_assist_allowedPrimaryUser()
|
D | MixedDeviceOwnerTest.java | 41 mUserId = mPrimaryUserId; in setUp() 148 DEVICE_ADMIN_PKG, ".AffiliationTest", "testSetAffiliationId1", mPrimaryUserId); in setUserAsAffiliatedUserToPrimary()
|
D | DeviceAndProfileOwnerTest.java | 680 installAppAsUser(ASSIST_APP_APK, mPrimaryUserId); in testScreenCaptureDisabled_assist() 809 boolean isManagedProfile = (mPrimaryUserId != mUserId); in testDelegatedCertInstaller() 1559 ImmutableMap.of(IS_PRIMARY_USER_PARAM, String.valueOf(mUserId == mPrimaryUserId)); in testSetStorageEncryption() 1983 if (userId == mPrimaryUserId) { in setScreenCaptureDisabled() 2003 installAppAsUser(DEVICE_ADMIN_APK, mPrimaryUserId); in setScreenCaptureDisabled_assist() 2005 if (userId == mPrimaryUserId) { in setScreenCaptureDisabled_assist() 2011 mPrimaryUserId); in setScreenCaptureDisabled_assist() 2021 mPrimaryUserId); in setScreenCaptureDisabled_assist() 2069 mPrimaryUserId, "secure", "voice_interaction_service", componentName); in setVoiceInteractionService() 2070 getDevice().setSetting(mPrimaryUserId, "secure", "assist_structure_enabled", "1"); in setVoiceInteractionService() [all …]
|
D | BaseDevicePolicyTest.java | 142 protected int mPrimaryUserId; field in BaseDevicePolicyTest 193 mPrimaryUserId = getPrimaryUser(); in setUp() 199 mFixedUsers.add(mPrimaryUserId); in setUp() 200 if (mPrimaryUserId != USER_SYSTEM) { in setUp() 206 switchUser(mPrimaryUserId); in setUp() 210 if (getDevice().getCurrentUser() != mPrimaryUserId) { in setUp() 489 runDeviceTestsAsUser(pkgName, testClassName, testMethodName, mPrimaryUserId); in runDeviceTests()
|
D | MixedProfileOwnerTestApi25.java | 30 mUserId = mPrimaryUserId; in setUp()
|
D | MixedProfileOwnerTest.java | 30 mUserId = mPrimaryUserId; in setUp()
|
D | CustomManagedProfileTest.java | 36 installAppAsUser(MANAGED_PROFILE_APK, mPrimaryUserId); in testIsProvisioningAllowed()
|
/cts/hostsidetests/appsecurity/src/android/appsecurity/cts/ |
D | PackageVisibilityTest.java | 58 installTestAppForUser(TEST_APK, mPrimaryUserId); in setUpPackage() 88 installTestAppForUser(TEST_APK, mPrimaryUserId); in testUninstalledPackageVisibility() 90 installTestAppForUser(TINY_APK, mPrimaryUserId); in testUninstalledPackageVisibility() 93 assertTrue(isAppVisibleForUser(TINY_PKG, mPrimaryUserId, MATCH_NORMAL)); in testUninstalledPackageVisibility() 94 assertTrue(isAppVisibleForUser(TINY_PKG, mPrimaryUserId, MATCH_UNINSTALLED)); in testUninstalledPackageVisibility() 98 ".PackageAccessTest", "testPackageAccess_inUser", mPrimaryUserId); in testUninstalledPackageVisibility() local 100 ".PackageAccessTest", "testPackageAccess_inUserUninstalled", mPrimaryUserId); in testUninstalledPackageVisibility() local 125 assertFalse(isAppVisibleForUser(TINY_PKG, mPrimaryUserId, MATCH_NORMAL)); in testUninstalledPackageVisibility() 126 assertFalse(isAppVisibleForUser(TINY_PKG, mPrimaryUserId, MATCH_UNINSTALLED)); in testUninstalledPackageVisibility() 140 mPrimaryUserId); in testUninstalledPackageVisibility() local [all …]
|
D | InstantAppUserTest.java | 63 private int mPrimaryUserId; field in InstantAppUserTest 75 mPrimaryUserId = getDevice().getPrimaryUserId(); in setUp() 172 runDeviceTestsAsUser(USER_TEST_PKG, TEST_CLASS, "testQueryInstant", mPrimaryUserId); in testInstallInstant() 182 runDeviceTestsAsUser(USER_TEST_PKG, TEST_CLASS, "testQueryFull", mPrimaryUserId); in testInstallFull() 191 installAppAsUser(USER_APK, mPrimaryUserId); in testInstallMultiple() 193 runDeviceTestsAsUser(USER_TEST_PKG, TEST_CLASS, "testQueryFull", mPrimaryUserId); in testInstallMultiple() 203 runDeviceTestsAsUser(USER_TEST_PKG, TEST_CLASS, "testQueryInstant", mPrimaryUserId); in testUpgradeExisting() 207 runDeviceTestsAsUser(USER_TEST_PKG, TEST_CLASS, "testQueryInstant", mPrimaryUserId); in testUpgradeExisting() 217 runDeviceTestsAsUser(USER_TEST_PKG, TEST_CLASS, "testQueryInstant", mPrimaryUserId); in testReplaceExisting() 221 runDeviceTestsAsUser(USER_TEST_PKG, TEST_CLASS, "testQueryInstant", mPrimaryUserId); in testReplaceExisting()
|
D | BaseAppSecurityTest.java | 36 protected int mPrimaryUserId; field in BaseAppSecurityTest 45 mPrimaryUserId = getDevice().getPrimaryUserId(); in setUpBaseAppSecurityTest() 47 mFixedUsers.add(mPrimaryUserId); in setUpBaseAppSecurityTest() 48 if (mPrimaryUserId != Utils.USER_SYSTEM) { in setUpBaseAppSecurityTest() 59 userId = mPrimaryUserId; in installTestAppForUser()
|
/cts/hostsidetests/multiuser/src/android/host/multiuser/ |
D | BaseMultiUserTest.java | 46 protected int mPrimaryUserId; field in BaseMultiUserTest 59 mPrimaryUserId = getDevice().getPrimaryUserId(); in setUp()
|