/cts/common/device-side/util-axt/src/com/android/compatibility/common/util/ |
D | AmUtils.java | 30 SystemUtil.runShellCommandForNoOutput("am make-uid-idle " + packageName); in runMakeUidIdle() 39 SystemUtil.runShellCommandForNoOutput("am kill --user cur " + packageName); in runKill() 50 final String output = SystemUtil.runShellCommand("ps -A -o NAME"); in isProcessRunning() 62 SystemUtil.runShellCommandForNoOutput("am set-standby-bucket " + packageName in setStandbyBucket() 71 final String value = SystemUtil.runShellCommand("am get-standby-bucket " + packageName); in getStandbyBucket() 81 SystemUtil.runCommandAndPrintOnLogcat(TAG, "am wait-for-broadcast-idle"); in waitForBroadcastIdle()
|
D | BatteryUtils.java | 55 SystemUtil.runShellCommandForNoOutput("cmd battery unplug"); in runDumpsysBatteryUnplug() 66 SystemUtil.runShellCommandForNoOutput(("cmd battery set level " + level)); in runDumpsysBatterySetLevel() 75 SystemUtil.runShellCommandForNoOutput(("cmd battery set ac " + (pluggedIn ? "1" : "0"))); in runDumpsysBatterySetPluggedIn() 101 SystemUtil.runShellCommandForNoOutput(("cmd battery reset")); in runDumpsysBatteryReset() 108 SystemUtil.runShellCommandForNoOutput( in enableAdaptiveBatterySaver() 118 SystemUtil.runShellCommandForNoOutput("cmd power set-mode 1"); in enableBatterySaver() 122 SystemUtil.runShellCommandForNoOutput("cmd power set-mode 0"); in enableBatterySaver() 137 SystemUtil.runShellCommandForNoOutput("input keyevent KEYCODE_WAKEUP"); in turnOnScreen() 141 SystemUtil.runShellCommandForNoOutput("input keyevent KEYCODE_SLEEP"); in turnOnScreen()
|
D | DeviceConfigStateHelper.java | 49 final String ogValue = SystemUtil.runWithShellPermissionIdentity( in maybeCacheOriginalValueLocked() 59 SystemUtil.runWithShellPermissionIdentity( in set() 70 SystemUtil.runWithShellPermissionIdentity( in set() 83 SystemUtil.runWithShellPermissionIdentity( in restoreOriginalValues()
|
D | AppStandbyUtils.java | 35 final String result = SystemUtil.runShellCommand( in isAppStandbyEnabled() 63 SystemUtil.runShellCommand("settings get global app_standby_enabled").trim(); in isAppStandbyEnabledAtRuntime() 72 return SystemUtil.callWithShellPermissionIdentity( in getAppStandbyBucket()
|
/cts/tests/app/src/android/app/cts/android/app/cts/tools/ |
D | ServiceProcessController.java | 32 import com.android.compatibility.common.util.SystemUtil; 113 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in denyBackgroundOp() 123 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in allowBackgroundOp() 130 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in denyAnyInBackgroundOp() 136 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in allowAnyInBackgroundOp() 141 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in makeUidIdle() 146 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in removeFromWhitelist() 151 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in addToWhitelist() 157 String result = SystemUtil.runShellCommand(mInstrumentation, cmd); in tempWhitelist() 163 SystemUtil.runShellCommand(mInstrumentation, cmd); in removeFromTempWhitelist() [all …]
|
/cts/tests/JobScheduler/src/android/jobscheduler/cts/ |
D | BatteryConstraintTest.java | 29 import com.android.compatibility.common.util.SystemUtil; 63 SystemUtil.runShellCommand(getInstrumentation(), "cmd jobscheduler monitor-battery on"); in setUp() 70 SystemUtil.runShellCommand(getInstrumentation(), "cmd jobscheduler monitor-battery off"); in tearDown() 71 SystemUtil.runShellCommand(getInstrumentation(), "cmd battery reset"); in tearDown() 97 SystemUtil.runShellCommand(getInstrumentation(), "cmd battery set ac 1"); in setBatteryState() 99 SystemUtil.runShellCommand(getInstrumentation(), "cmd battery unplug"); in setBatteryState() 101 int seq = Integer.parseInt(SystemUtil.runShellCommand(getInstrumentation(), in setBatteryState() 110 curSeq = Integer.parseInt(SystemUtil.runShellCommand(getInstrumentation(), in setBatteryState() 112 curCharging = Boolean.parseBoolean(SystemUtil.runShellCommand(getInstrumentation(), in setBatteryState() 124 boolean curCharging = Boolean.parseBoolean(SystemUtil.runShellCommand(getInstrumentation(), in verifyChargingState() [all …]
|
D | BaseJobSchedulerTest.java | 40 import com.android.compatibility.common.util.SystemUtil; 96 SystemUtil.runShellCommand(getInstrumentation(), "cmd activity set-inactive " in injectInstrumentation() 121 SystemUtil.runShellCommand(getInstrumentation(), "cmd battery reset"); in tearDown() 124 SystemUtil.runShellCommand(getInstrumentation(), "cmd devicestoragemonitor reset"); in tearDown() 127 SystemUtil.runShellCommand(getInstrumentation(), in tearDown() 168 res = SystemUtil.runShellCommand(getInstrumentation(), in setStorageStateLow() 171 res = SystemUtil.runShellCommand(getInstrumentation(), in setStorageStateLow() 180 curSeq = Integer.parseInt(SystemUtil.runShellCommand(getInstrumentation(), in setStorageStateLow() 191 return SystemUtil.runShellCommand(getInstrumentation(), in getJobState() 222 SystemUtil.runShellCommand(getInstrumentation(), in runSatisfiedJob()
|
/cts/tests/filesystem/src/android/filesystem/cts/ |
D | AlmostFullTest.java | 27 import com.android.compatibility.common.util.SystemUtil; 65 long freeDisk = SystemUtil.getFreeDiskSize(getContext()); in setUp() 88 Log.i(TAG, "free disk " + SystemUtil.getFreeDiskSize(getContext())); in setUp() 93 Log.i(TAG, "tearDown free disk " + SystemUtil.getFreeDiskSize(getContext())); in tearDown() 102 Log.i(TAG, "tearDown free disk " + SystemUtil.getFreeDiskSize(getContext())); in tearDown() 110 long freeDisk = SystemUtil.getFreeDiskSize(getContext()); in testSequentialUpdate() 129 long freeDisk = SystemUtil.getFreeDiskSize(getContext()); in testRandomRead() 144 long freeDisk = SystemUtil.getFreeDiskSize(getContext()); in testRandomUpdate()
|
/cts/tests/tests/permission/src/android/permission/cts/ |
D | StorageEscalationTest.kt | 30 import com.android.compatibility.common.util.SystemUtil in <lambda>() 59 SystemUtil.runShellCommand("pm uninstall $APP_PACKAGE_NAME --user ALL") in <lambda>() 67 val result = SystemUtil.runShellCommand("pm install -r$userString $apk") in <lambda>() 73 val createUserOutput: String = SystemUtil.runShellCommand("pm create-user secondary") in <lambda>() 82 SystemUtil.runShellCommand("am start-user -w $userId") in <lambda>() 89 SystemUtil.runShellCommand("pm remove-user $userId") in <lambda>() 108 SystemUtil.runWithShellPermissionIdentity { in <lambda>()
|
D | UndefinedGroupPermissionTest.kt | 31 import com.android.compatibility.common.util.SystemUtil 32 import com.android.compatibility.common.util.SystemUtil.eventually 54 SystemUtil.runShellCommand("pm install -r " + in install() 82 SystemUtil.runShellCommand("input keyevent KEYCODE_WAKEUP") in wakeUpScreenAndUnlock() 83 SystemUtil.runShellCommand("input keyevent KEYCODE_MENU") in wakeUpScreenAndUnlock() 129 SystemUtil.runShellCommand("pm uninstall $APP_PKG_NAME") in uninstall() 148 SystemUtil.runWithShellPermissionIdentity { in testOtherGroupPermissionsNotGranted()
|
D | NearbyDevicesRenouncePermissionTest.java | 24 import static com.android.compatibility.common.util.SystemUtil.runShellCommandOrThrow; 53 import com.android.compatibility.common.util.SystemUtil; 156 SystemUtil.eventually(() -> { in scanWithoutRenouncingNotesBluetoothAndLocation() 167 SystemUtil.eventually(() -> { in scanRenouncingLocationNotesBluetoothButNotLocation() 178 SystemUtil.eventually(() -> { in scanRenouncingInMiddleOfChainNotesBluetoothButNotLocation() 189 SystemUtil.eventually(() -> { in scanRenouncingAtEndOfChainNotesBluetoothButNotLocation() 243 return SystemUtil.callWithShellPermissionIdentity(() -> in createContext() 253 return SystemUtil.callWithShellPermissionIdentity(() -> in createContext() 264 return SystemUtil.callWithShellPermissionIdentity(() -> in createContext()
|
D | OneTimePermissionTest.java | 25 import static com.android.compatibility.common.util.SystemUtil.eventually; 26 import static com.android.compatibility.common.util.SystemUtil.runShellCommand; 27 import static com.android.compatibility.common.util.SystemUtil.runWithShellPermissionIdentity; 40 import com.android.compatibility.common.util.SystemUtil; 81 SystemUtil.runShellCommand("input keyevent KEYCODE_WAKEUP"); in wakeUpScreen() 83 SystemUtil.runShellCommand("input keyevent 82"); in wakeUpScreen() 163 SystemUtil.runWithShellPermissionIdentity(() -> in testPermissionRevokedOnKill()
|
/cts/tests/app/src/android/app/cts/ |
D | ApplicationTest.java | 33 import com.android.compatibility.common.util.SystemUtil; 45 SystemUtil.runShellCommand(getInstrumentation(), ERASE_FONT_SCALE_CMD); in tearDown() 78 SystemUtil.runShellCommand(getInstrumentation(), ERASE_FONT_SCALE_CMD); in toggleFontScale() 80 SystemUtil.runShellCommand(getInstrumentation(), PUT_FONT_SCALE_CMD); in toggleFontScale() 82 SystemUtil.runShellCommand(getInstrumentation(), ERASE_FONT_SCALE_CMD); in toggleFontScale()
|
D | ActivityManagerTest.java | 82 import com.android.compatibility.common.util.SystemUtil; 520 String[] configs = SystemUtil.runShellCommand( 779 SystemUtil.runWithShellPermissionIdentity( in testForceStopPackageWontRestartProcess() 806 List<RunningAppProcessInfo> runningApps = SystemUtil.callWithShellPermissionIdentity( in testForceStopPackageWontRestartProcess() 811 runningApps = SystemUtil.callWithShellPermissionIdentity(() -> { in testForceStopPackageWontRestartProcess() 858 SystemUtil.runWithShellPermissionIdentity(() -> { in testAppNotResponding() 909 SystemUtil.runWithShellPermissionIdentity(() -> { in testKillingPidsOnImperceptible() 914 SystemUtil.runWithShellPermissionIdentity(() -> { in testKillingPidsOnImperceptible() 961 SystemUtil.runWithShellPermissionIdentity(() -> { in testKillingPidsOnImperceptible() 990 SystemUtil.runShellCommand(mInstrumentation, in testKillingAppChildProcess() [all …]
|
/cts/tests/JobSchedulerSharedUid/src/android/jobscheduler/cts/shareduidtests/ |
D | ConstraintTest.java | 35 import com.android.compatibility.common.util.SystemUtil; 94 SystemUtil.runShellCommand(getInstrumentation(), "cmd activity set-inactive " in injectInstrumentation() 117 SystemUtil.runShellCommand(getInstrumentation(), "cmd devicestoragemonitor reset"); in tearDown() 163 res = SystemUtil.runShellCommand(getInstrumentation(), in setStorageState() 166 res = SystemUtil.runShellCommand(getInstrumentation(), in setStorageState() 175 curSeq = Integer.parseInt(SystemUtil.runShellCommand(getInstrumentation(), in setStorageState() 186 return SystemUtil.runShellCommand(getInstrumentation(), in getJobState()
|
/cts/tests/tests/contactsprovider/src/android/provider/cts/contacts/ |
D | ContactsContract_SimContactTest.java | 32 import com.android.compatibility.common.util.SystemUtil; 73 SystemUtil.runWithShellPermissionIdentity(() -> { in tearDown() 85 SystemUtil.runWithShellPermissionIdentity(() -> { in testAddSimAccount_returnedByGetSimAccounts() 118 SystemUtil.runWithShellPermissionIdentity(() -> { in testAddSimAccount_broadcastsChange() 134 SystemUtil.runWithShellPermissionIdentity(() -> { in testRemoveSimAccount_broadcastsChange() 141 SystemUtil.runWithShellPermissionIdentity(() -> { in testRemoveSimAccount_broadcastsChange()
|
/cts/tests/tests/sensorprivacy/src/android/sensorprivacy/cts/ |
D | SensorPrivacyMicrophoneTest.kt | 24 import com.android.compatibility.common.util.SystemUtil 39 SystemUtil.runWithShellPermissionIdentity { in testMicShownOnPhoneCall() 47 SystemUtil.runWithShellPermissionIdentity { in testMicShownOnPhoneCall()
|
/cts/tests/inputmethod/src/android/view/inputmethod/cts/util/ |
D | TestUtils.java | 19 import static com.android.compatibility.common.util.SystemUtil.runShellCommand; 20 import static com.android.compatibility.common.util.SystemUtil.runShellCommandOrThrow; 21 import static com.android.compatibility.common.util.SystemUtil.runWithShellPermissionIdentity; 35 import com.android.compatibility.common.util.SystemUtil; 168 SystemUtil.runWithShellPermissionIdentity( in unlockScreen()
|
/cts/tests/tests/print/src/android/print/cts/ |
D | InstallBehavior.java | 27 import com.android.compatibility.common.util.SystemUtil; 51 SystemUtil.runShellCommand(getInstrumentation(), in uninstallExternalPrintService() 84 SystemUtil.runShellCommand(getInstrumentation(), in installedServiceIsEnabled()
|
/cts/tests/tests/content/lib/accountaccess/src/com.android.cts.content/ |
D | Utils.java | 24 import com.android.compatibility.common.util.SystemUtil; 70 SystemUtil.runShellCommand(InstrumentationRegistry.getInstrumentation(), in allowSyncAdapterRunInBackgroundAndDataInBackground() 73 SystemUtil.runShellCommand(InstrumentationRegistry.getInstrumentation(), in allowSyncAdapterRunInBackgroundAndDataInBackground() 79 SystemUtil.runShellCommand(InstrumentationRegistry.getInstrumentation(), in disallowSyncAdapterRunInBackgroundAndDataInBackground() 82 SystemUtil.runShellCommand(InstrumentationRegistry.getInstrumentation(), in disallowSyncAdapterRunInBackgroundAndDataInBackground()
|
/cts/tests/AlarmManager/util/src/android/alarmmanager/util/ |
D | AlarmManagerDeviceConfigHelper.java | 25 import com.android.compatibility.common.util.SystemUtil; 44 initialProperties = SystemUtil.callWithShellPermissionIdentity( in AlarmManagerDeviceConfigHelper() 83 final String output = SystemUtil.runShellCommand("cmd alarm get-config-version").trim(); in getCurrentConfigVersion() 89 SystemUtil.runWithShellPermissionIdentity( in commitAndAwaitPropagation()
|
/cts/tests/framework/base/windowmanager/src/android/server/wm/ |
D | DreamManagerServiceTests.java | 42 import com.android.compatibility.common.util.SystemUtil; 75 SystemUtil.runWithShellPermissionIdentity(() -> { in setup() 84 SystemUtil.runWithShellPermissionIdentity(() -> { in reset() 92 SystemUtil.runWithShellPermissionIdentity(() -> { in startDream() 99 SystemUtil.runWithShellPermissionIdentity(() -> { in stopDream() 106 SystemUtil.runWithShellPermissionIdentity(() -> { in setActiveDream() 114 return SystemUtil.runWithShellPermissionIdentity(() -> { in getIsDreaming()
|
/cts/tests/AlarmManager/src/android/alarmmanager/cts/ |
D | ExactAlarmsTest.java | 56 import com.android.compatibility.common.util.SystemUtil; 151 SystemUtil.runShellCommandForNoOutput("dumpsys battery reset"); in putDeviceToIdle() 152 SystemUtil.runShellCommand("cmd deviceidle force-idle deep"); in putDeviceToIdle() 158 SystemUtil.runShellCommand("am compat enable --no-kill REQUIRE_EXACT_ALARM_PERMISSION " in enableChange() 166 SystemUtil.runShellCommand("am compat reset --no-kill REQUIRE_EXACT_ALARM_PERMISSION " in resetChanges() 176 SystemUtil.runWithShellPermissionIdentity( in removeFromWhitelists() 178 SystemUtil.runShellCommand("cmd deviceidle tempwhitelist -r " + packageName); in removeFromWhitelists() 183 SystemUtil.runShellCommand("cmd deviceidle unforce"); in restoreBatteryState() 184 SystemUtil.runShellCommandForNoOutput("dumpsys battery reset"); in restoreBatteryState() 189 SystemUtil.runWithShellPermissionIdentity( in restorePermissionReceiverState() [all …]
|
D | TimeChangeTests.java | 41 import com.android.compatibility.common.util.SystemUtil; 91 SystemUtil.runWithShellPermissionIdentity(() -> mAlarmManager.setTime(rtcToSet)); in setTime() 96 String auto_time = SystemUtil.runShellCommand("settings get global auto_time"); in isAutoTimeEnabled() 114 SystemUtil.runShellCommand("settings put global auto_time 0"); in setUp() 156 SystemUtil.runShellCommand("settings put global auto_time 1"); in tearDown()
|
/cts/libs/install/src/com/android/cts/install/lib/ |
D | Install.java | 24 import com.android.compatibility.common.util.SystemUtil; 222 SystemUtil.runShellCommandForNoOutput("pm bypass-staged-installer-check true"); in createEmptyInstallSession() 225 SystemUtil.runShellCommandForNoOutput("pm bypass-allowed-apex-update-check true"); in createEmptyInstallSession() 247 SystemUtil.runShellCommandForNoOutput("pm bypass-staged-installer-check false"); in createEmptyInstallSession() 250 SystemUtil.runShellCommandForNoOutput("pm bypass-allowed-apex-update-check false"); in createEmptyInstallSession()
|