Home
last modified time | relevance | path

Searched refs:getWho (Results 1 – 25 of 33) sorted by relevance

12

/cts/hostsidetests/devicepolicy/app/DeviceOwner/src/com/android/cts/deviceowner/
DUserSessionTest.java26 mDevicePolicyManager.setLogoutEnabled(getWho(), true); in testSetLogoutEnabled()
31 mDevicePolicyManager.setLogoutEnabled(getWho(), false); in testSetLogoutDisabled()
36 mDevicePolicyManager.setStartUserSessionMessage(getWho(), START_SESSION_MESSAGE); in testSetStartUserSessionMessage()
38 mDevicePolicyManager.getStartUserSessionMessage(getWho())); in testSetStartUserSessionMessage()
42 mDevicePolicyManager.setEndUserSessionMessage(getWho(), END_SESSION_MESSAGE); in testSetEndUserSessionMessage()
43 assertEquals(END_SESSION_MESSAGE, mDevicePolicyManager.getEndUserSessionMessage(getWho())); in testSetEndUserSessionMessage()
47 mDevicePolicyManager.setStartUserSessionMessage(getWho(), START_SESSION_MESSAGE); in testClearStartUserSessionMessage()
48 mDevicePolicyManager.setStartUserSessionMessage(getWho(), null); in testClearStartUserSessionMessage()
49 assertNull(mDevicePolicyManager.getStartUserSessionMessage(getWho())); in testClearStartUserSessionMessage()
54 mDevicePolicyManager.setEndUserSessionMessage(getWho(), END_SESSION_MESSAGE); in testClearEndUserSessionMessage()
[all …]
DDevicePolicyLoggingTest.java33 mDevicePolicyManager.setKeyguardDisabled(getWho(), true); in testSetKeyguardDisabledLogged()
34 mDevicePolicyManager.setKeyguardDisabled(getWho(), false); in testSetKeyguardDisabledLogged()
38 mDevicePolicyManager.setStatusBarDisabled(getWho(), true); in testSetStatusBarDisabledLogged()
39 mDevicePolicyManager.setStatusBarDisabled(getWho(), false); in testSetStatusBarDisabledLogged()
53 mDevicePolicyManager.setGlobalSetting(getWho(), AUTO_TIME, "1"); in testSetGlobalSettingLogged()
54 mDevicePolicyManager.setGlobalSetting(getWho(), AUTO_TIME_ZONE, "1"); in testSetGlobalSettingLogged()
55 mDevicePolicyManager.setGlobalSetting(getWho(), DATA_ROAMING, "1"); in testSetGlobalSettingLogged()
56 mDevicePolicyManager.setGlobalSetting(getWho(), USB_MASS_STORAGE_ENABLED, "1"); in testSetGlobalSettingLogged()
58 mDevicePolicyManager.setGlobalSetting(getWho(), AUTO_TIME, autoTimeOriginalValue); in testSetGlobalSettingLogged()
60 getWho(), AUTO_TIME_ZONE, autoTimeZoneOriginalValue); in testSetGlobalSettingLogged()
[all …]
DPrivateDnsPolicyTest.java46 mDevicePolicyManager.setGlobalPrivateDnsModeOpportunistic(getWho()); in tearDown()
63 mDevicePolicyManager.addUserRestriction(getWho(), restriction); in setUserRestriction()
65 mDevicePolicyManager.clearUserRestriction(getWho(), restriction); in setUserRestriction()
74 int resultCode = mDevicePolicyManager.setGlobalPrivateDnsModeOpportunistic(getWho()); in callSetGlobalPrivateDnsOpportunisticModeExpectingResult()
91 getWho(), privateDnsHost); in callSetGlobalPrivateDnsHostModeExpectingResult()
106 mDevicePolicyManager.getGlobalPrivateDnsMode(getWho())).isEqualTo( in testSetOpportunisticMode()
108 assertThat(mDevicePolicyManager.getGlobalPrivateDnsHost(getWho())).isNull(); in testSetOpportunisticMode()
117 mDevicePolicyManager.getGlobalPrivateDnsMode(getWho())).isEqualTo( in testSetSpecificHostMode()
120 mDevicePolicyManager.getGlobalPrivateDnsHost(getWho())).isEqualTo( in testSetSpecificHostMode()
127 () -> mDevicePolicyManager.setGlobalPrivateDnsModeSpecifiedHost(getWho(), null)); in testSetModeWithIncorrectHost()
[all …]
DBackupServicePoliciesTest.java26 assertFalse(mDevicePolicyManager.isBackupServiceEnabled(getWho())); in testEnablingAndDisablingBackupService()
27 mDevicePolicyManager.setBackupServiceEnabled(getWho(), true); in testEnablingAndDisablingBackupService()
28 assertTrue(mDevicePolicyManager.isBackupServiceEnabled(getWho())); in testEnablingAndDisablingBackupService()
29 mDevicePolicyManager.setBackupServiceEnabled(getWho(), false); in testEnablingAndDisablingBackupService()
30 assertFalse(mDevicePolicyManager.isBackupServiceEnabled(getWho())); in testEnablingAndDisablingBackupService()
DOverrideApnTest.java85 List <ApnSetting> apnList = mDevicePolicyManager.getOverrideApns(getWho()); in tearDown()
87 boolean deleted = mDevicePolicyManager.removeOverrideApn(getWho(), apn.getId()); in tearDown()
90 mDevicePolicyManager.setOverrideApnsEnabled(getWho(), false); in tearDown()
94 int insertedId = mDevicePolicyManager.addOverrideApn(getWho(), testApnFull); in testAddGetRemoveOverrideApn()
96 List <ApnSetting> apnList = mDevicePolicyManager.getOverrideApns(getWho()); in testAddGetRemoveOverrideApn()
120 assertTrue(mDevicePolicyManager.removeOverrideApn(getWho(), insertedId)); in testAddGetRemoveOverrideApn()
121 apnList = mDevicePolicyManager.getOverrideApns(getWho()); in testAddGetRemoveOverrideApn()
126 assertFalse(mDevicePolicyManager.removeOverrideApn(getWho(), -1)); in testRemoveOverrideApnFailsForIncorrectId()
130 mDevicePolicyManager.addOverrideApn(getWho(), testApnFull); in testInsertConflictingApn()
131 int insertConflictingId = mDevicePolicyManager.addOverrideApn(getWho(), testApnFull); in testInsertConflictingApn()
[all …]
DSetTimeTest.java69 assertTrue("failed to set time", mDevicePolicyManager.setTime(getWho(), testTime)); in testSetTimeWithValue()
80 mDevicePolicyManager.setGlobalSetting(getWho(), Settings.Global.AUTO_TIME, "0"); in testSetTime()
86 mDevicePolicyManager.setGlobalSetting(getWho(), Settings.Global.AUTO_TIME, "1"); in testSetTimeFailWithAutoTimeOn()
87 assertFalse(mDevicePolicyManager.setTime(getWho(), TEST_TIME_1)); in testSetTimeFailWithAutoTimeOn()
104 mDevicePolicyManager.setTimeZone(getWho(), testTimeZone)); in testSetTimeZoneWithValue()
122 mDevicePolicyManager.setGlobalSetting(getWho(), Settings.Global.AUTO_TIME_ZONE, "0"); in testSetTimeZone()
134 mDevicePolicyManager.setGlobalSetting(getWho(), Settings.Global.AUTO_TIME_ZONE, "1"); in testSetTimeZone()
139 mDevicePolicyManager.setGlobalSetting(getWho(), Settings.Global.AUTO_TIME_ZONE, "1"); in testSetTimeZoneFailWithAutoTimezoneOn()
140 assertFalse(mDevicePolicyManager.setTimeZone(getWho(), TEST_TIME_ZONE_1)); in testSetTimeZoneFailWithAutoTimezoneOn()
149 mDevicePolicyManager.setGlobalSetting(getWho(), Settings.Global.AUTO_TIME, "0"); in restoreTime()
[all …]
DAdminActionBookkeepingTest.java47 mDevicePolicyManager.setSecurityLoggingEnabled(getWho(), false); in tearDown()
48 mDevicePolicyManager.setNetworkLoggingEnabled(getWho(), false); in tearDown()
49 mDevicePolicyManager.uninstallCaCert(getWho(), TestCertificates.TEST_CA.getBytes()); in tearDown()
63 mDevicePolicyManager.setSecurityLoggingEnabled(getWho(), true); in testRetrieveSecurityLogs()
66 mDevicePolicyManager.retrieveSecurityLogs(getWho()); in testRetrieveSecurityLogs()
76 mDevicePolicyManager.retrievePreRebootSecurityLogs(getWho()) != null; in testRetrieveSecurityLogs()
106 mDevicePolicyManager.requestBugreport(getWho()); in testRequestBugreport()
159 mDevicePolicyManager.setNetworkLoggingEnabled(getWho(), true); in testGetLastNetworkLogRetrievalTime()
162 mDevicePolicyManager.retrieveNetworkLogs(getWho(), 0 /* batchToken */); in testGetLastNetworkLogRetrievalTime()
176 mDevicePolicyManager.setOrganizationName(getWho(), null); in testDeviceOwnerOrganizationName()
[all …]
DBluetoothRestrictionTest.java52 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_BLUETOOTH); in tearDown()
65 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_BLUETOOTH); in testEnableBluetoothFailsWhenDisallowed()
80 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_BLUETOOTH); in testBluetoothGetsDisabledAfterRestrictionSet()
92 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_BLUETOOTH); in testEnableBluetoothSucceedsAfterRestrictionRemoved()
98 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_BLUETOOTH); in testEnableBluetoothSucceedsAfterRestrictionRemoved()
127 mDevicePolicyManager.addUserRestriction(getWho(), restriction); in testOppDisabledWhenRestrictionSet()
134 mDevicePolicyManager.clearUserRestriction(getWho(), restriction); in testOppDisabledWhenRestrictionSet()
DSensorToggleRestrictionTest.java46 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_CAMERA_TOGGLE); in tearDown()
47 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_MICROPHONE_TOGGLE); in tearDown()
59 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_CAMERA_TOGGLE); in testCameraToggle_RestrictionSet_CannotChangeSensorPrivacy()
76 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_MICROPHONE_TOGGLE); in testMicrophoneToggle_RestrictionSet_CannotChangeSensorPrivacy()
92 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_CAMERA_TOGGLE); in testCameraToggle_RestrictionSet_ResetSensorPrivacy()
111 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_MICROPHONE_TOGGLE); in testMicrophoneToggle_RestrictionSet_ResetSensorPrivacy()
DUserControlDisabledPackagesTest.java48 mDevicePolicyManager.setUserControlDisabledPackages(getWho(), protectedPackages); in testSetUserControlDisabledPackages()
67 assertThat(mDevicePolicyManager.getUserControlDisabledPackages(getWho())) in testForceStopWithUserControlDisabled()
74 mDevicePolicyManager.setUserControlDisabledPackages(getWho(), pkgs); in testClearSetUserControlDisabledPackages()
75 assertThat(mDevicePolicyManager.getUserControlDisabledPackages(getWho())).isEmpty(); in testClearSetUserControlDisabledPackages()
80 assertThat(mDevicePolicyManager.getUserControlDisabledPackages(getWho())).isEmpty(); in testForceStopWithUserControlEnabled()
DAirplaneModeRestrictionTest.java43 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_AIRPLANE_MODE); in setUp()
49 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_AIRPLANE_MODE); in tearDown()
69 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_AIRPLANE_MODE); in testAirplaneModeTurnedOffWhenRestrictionSet()
81 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_AIRPLANE_MODE); in testAirplaneModeCannotBeTurnedOnWithRestrictionOn()
DBaseAffiliatedProfileOwnerTest.java51 assertTrue(mDevicePolicyManager.isAdminActive(getWho())); in assertDeviceOrAffiliatedProfileOwner()
59 protected ComponentName getWho() { in getWho() method in BaseAffiliatedProfileOwnerTest
DCreateAndManageUserTest.java71 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_ADD_USER); in tearDown()
72 mDevicePolicyManager.clearUserRestriction(getWho(), UserManager.DISALLOW_REMOVE_USER); in tearDown()
109 List<UserHandle> secondaryUsers = mDevicePolicyManager.getSecondaryUsers(getWho()); in testCreateAndManageUser_GetSecondaryUsers()
163 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_REMOVE_USER); in testCreateAndManageUser_StopEphemeralUser_DisallowRemoveUser()
299 mDevicePolicyManager.setAffiliationIds(getWho(), Collections.singleton(AFFILIATION_ID)); in runCrossUserVerification()
326 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_ADD_USER); in testCreateAndManageUser_AddRestrictionSet()
332 mDevicePolicyManager.addUserRestriction(getWho(), UserManager.DISALLOW_REMOVE_USER); in testCreateAndManageUser_RemoveRestrictionSet()
356 return createAndManageUser(/* profileOwner= */ getWho(), /* adminExtras= */ null, flags); in createAndManageUser()
368 /* admin= */ getWho(), in createAndManageUser()
392 boolean switched = mDevicePolicyManager.switchUser(getWho(), userHandle); in switchUserAndWaitForBroadcasts()
[all …]
DRemoteBugreportTest.java36 mDevicePolicyManager.requestBugreport(getWho()); in testRequestBugreportThrowsSecurityException()
DSetLocationEnabledTest.java91 mDevicePolicyManager.setLocationEnabled(getWho(), enabled); in setLocationEnabledAndWaitIfNecessary()
114 mDevicePolicyManager.setLocationEnabled(getWho(), enabled); in setLocationEnabledAndWaitIfNecessary()
DBaseDeviceOwnerTest.java104 ComponentName admin = getWho(); in assertDeviceOwner()
115 protected ComponentName getWho() { in getWho() method in BaseDeviceOwnerTest
/cts/hostsidetests/devicepolicy/app/ProfileOwner/src/com/android/cts/profileowner/
DBackupServicePoliciesTest.java9 assertFalse(mDevicePolicyManager.isBackupServiceEnabled(getWho())); in testEnablingAndDisablingBackupService()
10 mDevicePolicyManager.setBackupServiceEnabled(getWho(), true); in testEnablingAndDisablingBackupService()
11 assertTrue(mDevicePolicyManager.isBackupServiceEnabled(getWho())); in testEnablingAndDisablingBackupService()
12 mDevicePolicyManager.setBackupServiceEnabled(getWho(), false); in testEnablingAndDisablingBackupService()
13 assertFalse(mDevicePolicyManager.isBackupServiceEnabled(getWho())); in testEnablingAndDisablingBackupService()
DAdminActionBookkeepingTest.java33 mDevicePolicyManager.uninstallCaCert(getWho(), TestCertificates.TEST_CA.getBytes()); in tearDown()
50 mDevicePolicyManager.setSecureSetting(getWho(), setting, "com.test.2"); in testIsDefaultInputMethodSet()
71 assertTrue(mDevicePolicyManager.installCaCert(getWho(), rawCert)); in testGetPolicyInstalledCaCerts()
79 mDevicePolicyManager.uninstallCaCert(getWho(), rawCert); in testGetPolicyInstalledCaCerts()
DDevicePolicySafetyCheckerIntegrationTest.java36 mTester.testAllOperations(mDevicePolicyManager, getWho()); in testAllOperations()
50 mTester.testUnsafeStateException(mDevicePolicyManager, getWho()); in testUnsafeStateException()
DBaseProfileOwnerTest.java63 assertTrue(dpm.isAdminActive(getWho())); in assertProfileOwner()
67 protected static ComponentName getWho() { in getWho() method in BaseProfileOwnerTest
/cts/tests/tests/packageinstaller/adminpackageinstaller/src/android/packageinstaller/admin/cts/
DSilentPackageInstallTest.java42 mDevicePolicyManager.setUninstallBlocked(getWho(), TEST_APP_PKG, true); in testUninstallBlocked()
43 assertTrue(mDevicePolicyManager.isUninstallBlocked(getWho(), TEST_APP_PKG)); in testUninstallBlocked()
48 mDevicePolicyManager.setUninstallBlocked(getWho(), TEST_APP_PKG, false); in testUninstallBlocked()
49 assertFalse(mDevicePolicyManager.isUninstallBlocked(getWho(), TEST_APP_PKG)); in testUninstallBlocked()
/cts/hostsidetests/devicepolicy/app/DeviceAndProfileOwner/src/com/android/cts/deviceandprofileowner/
DLockScreenInfoTest.java25 mDevicePolicyManager.setDeviceOwnerLockScreenInfo(getWho(), null); in tearDown()
45 mDevicePolicyManager.setDeviceOwnerLockScreenInfo(getWho(), message); in testEmptyStringClearsLockInfo()
85 mDevicePolicyManager.setDeviceOwnerLockScreenInfo(getWho(), message); in setLockInfo()
89 protected ComponentName getWho() { in getWho() method in LockScreenInfoTest
DDeviceIdAttestationTest.java32 getWho()); in testFailsWithoutProfileOwnerIdsGrant()
40 mDevicePolicyManager, getWho()); in testSucceedsWithProfileOwnerIdsGrant()
44 protected ComponentName getWho() { in getWho() method in DeviceIdAttestationTest
DKeyManagementTest.java131 mDevicePolicyManager.removeKeyPair(getWho(), TEST_ALIAS); in tearDown()
142 getWho(), mFakePrivKey, new Certificate[] {mFakeCert}, grant, true)) in testCanInstallWithAutomaticAccess()
152 assertThat(mDevicePolicyManager.removeKeyPair(getWho(), grant)).isTrue(); in testCanInstallWithAutomaticAccess()
177 assertThat(mDevicePolicyManager.installKeyPair(getWho(), privKey, certChain, alias, true)) in testCanInstallCertChain()
190 assertThat(mDevicePolicyManager.removeKeyPair(getWho(), alias)).isTrue(); in testCanInstallCertChain()
234 getWho(), "RSA", buildRsaKeySpec(alias, false /* useStrongBox */), 0); in testCanGenerateRSAKeyPair()
238 assertThat(mDevicePolicyManager.removeKeyPair(getWho(), alias)).isTrue(); in testCanGenerateRSAKeyPair()
247 getWho(), "RSA", buildRsaKeySpec(alias, true /* useStrongBox */), 0); in testCanGenerateRSAKeyPairUsingStrongBox()
249 assertThat(mDevicePolicyManager.removeKeyPair(getWho(), alias)).isTrue(); in testCanGenerateRSAKeyPairUsingStrongBox()
269 getWho(), "EC", buildEcKeySpec(alias, false /* useStrongBox */), 0); in testCanGenerateECKeyPair()
[all …]
/cts/hostsidetests/devicepolicy/app/CorpOwnedManagedProfile/src/com/android/cts/comp/
DAdminReceiver.java40 getManager(context).setProfileEnabled(getWho(context)); in onProfileProvisioningComplete()
41 getManager(context).setProfileName(getWho(context), "Corp owned Managed Profile"); in onProfileProvisioningComplete()

12