Home
last modified time | relevance | path

Searched refs:executeShellCommand (Results 1 – 25 of 59) sorted by relevance

123

/platform_testing/libraries/collectors-helper/memory/test/src/com/android/helpers/tests/
DGarbageCollectionHelperTest.java60 }).when(mUiDevice).executeShellCommand(any()); in setUp()
83 inOrder.verify(mUiDevice).executeShellCommand("pidof package.name1"); in testOneAppToGc()
84 inOrder.verify(mUiDevice).executeShellCommand("kill -10 1"); in testOneAppToGc()
96 inOrder.verify(mUiDevice).executeShellCommand("pidof package.name1"); in testMultipleAppsToGc()
97 inOrder.verify(mUiDevice).executeShellCommand("kill -10 1"); in testMultipleAppsToGc()
98 inOrder.verify(mUiDevice).executeShellCommand("pidof package.name2"); in testMultipleAppsToGc()
99 inOrder.verify(mUiDevice).executeShellCommand("kill -10 2"); in testMultipleAppsToGc()
100 inOrder.verify(mUiDevice).executeShellCommand("pidof package.name3"); in testMultipleAppsToGc()
101 inOrder.verify(mUiDevice).executeShellCommand("kill -10 3"); in testMultipleAppsToGc()
113 inOrder.verify(mUiDevice).executeShellCommand("pidof does.not.exist"); in testSkipsGcOnDneApp()
[all …]
/platform_testing/libraries/collectors-helper/statsd/test/src/com/android/helpers/
DHelperTestUtility.java59 public static String executeShellCommand(String cmd) { in executeShellCommand() method in HelperTestUtility
61 return getUiDevice().executeShellCommand(cmd); in executeShellCommand()
72 executeShellCommand(CLEAR_CACHE_CMD); in clearCache()
82 executeShellCommand(killCmd); in clearApp()
90 executeShellCommand(String.format(KEYEVENT_CMD_TEMPLATE, keyCode)); in sendKeyCode()
98 executeShellCommand(String.format(LAUNCH_APP_CMD_TEMPLATE, pkgName)); in launchPackageViaAdb()
117 executeShellCommand(UNLOCK_CMD); in wakeUpAndUnlock()
DCrashHelperTest.java113 HelperTestUtility.executeShellCommand(START_APP); in testCrashMetric()
132 HelperTestUtility.executeShellCommand(START_APP); in testNativeCrashMetric()
151 HelperTestUtility.executeShellCommand(START_APP); in testAnrMetric()
171 HelperTestUtility.executeShellCommand(START_APP); in testMultipleCrashMetric()
175 HelperTestUtility.executeShellCommand(START_APP); in testMultipleCrashMetric()
179 HelperTestUtility.executeShellCommand(START_APP); in testMultipleCrashMetric()
/platform_testing/libraries/health/rules/tests/src/android/platform/test/rule/
DCompilationFilterRuleTest.java69 protected String executeShellCommand(String cmd) { in testAppToCompile_failCompilationThrows()
70 super.executeShellCommand(cmd); in testAppToCompile_failCompilationThrows()
89 protected String executeShellCommand(String cmd) { in testOneAppToCompile()
90 super.executeShellCommand(cmd); in testOneAppToCompile()
110 protected String executeShellCommand(String cmd) { in testMultipleAppsToCompile()
111 super.executeShellCommand(cmd); in testMultipleAppsToCompile()
136 protected String executeShellCommand(String cmd) { in testMultipleAppsToCompileInSpeedProfile()
137 super.executeShellCommand(cmd); in testMultipleAppsToCompileInSpeedProfile()
169 protected String executeShellCommand(String cmd) { in executeShellCommand() method in CompilationFilterRuleTest.TestableCompilationFilterRule
/platform_testing/libraries/health/rules/src/android/platform/test/rule/
DDisableAutofillRule.java39 String result = uiDevice.executeShellCommand("settings get secure autofill_service"); in starting()
43 uiDevice.executeShellCommand("settings put secure autofill_service null"); in starting()
53 .executeShellCommand( in finished()
DIorapCompilationRule.java86 String result = executeShellCommand("whoami"); in checkIfRoot()
98 executeShellCommand(String.format(IORAP_MAINTENANCE_CMD, packageName)); in purgeIorapPackage()
121 executeShellCommand(String.format("setprop iorapd.perfetto.enable %b", enable)); in toggleIorapStatus()
122 executeShellCommand(String.format("setprop iorapd.readahead.enable %b", enable)); in toggleIorapStatus()
123 executeShellCommand(String.format( in toggleIorapStatus()
125 executeShellCommand(String.format("dumpsys iorapd --refresh-properties")); in toggleIorapStatus()
155 executeShellCommand(String.format(IORAP_COMPILE_CMD, appPkgName)); in compileAppForIorap()
180 String output = executeShellCommand(IORAP_DUMPSYS_CMD); in waitForIorapCompiled()
DTestWatcher.java51 protected String executeShellCommand(String cmd) { in executeShellCommand() method in TestWatcher
54 return getUiDevice().executeShellCommand(cmd); in executeShellCommand()
DKillAppsRule.java49 executeShellCommand(String.format("am force-stop %s", app)); in starting()
DCompilationFilterRule.java86 String response = executeShellCommand(String.format(DUMP_PROFILE_CMD, app)); in finished()
96 String response = executeShellCommand( in finished()
/platform_testing/libraries/system-helpers/commands-helper/src/android/system/helpers/
DCommandsHelper.java76 public String executeShellCommand(String command) { in executeShellCommand() method in CommandsHelper
78 return UiDevice.getInstance(mInstrumentation).executeShellCommand(command); in executeShellCommand()
95 return Arrays.asList(executeShellCommand(command).split(separatorChars)); in executeShellCommandAndSplitOutput()
105 return getInstance().executeShellCommand(command); in execute()
/platform_testing/libraries/device-collectors/src/test/java/android/device/collectors/
DScreenRecordCollectorTest.java94 doReturn("1234").when(mDevice).executeShellCommand(eq("pidof screenrecord")); in initListener()
95 doReturn("").when(mDevice).executeShellCommand(not(eq("pidof screenrecord"))); in initListener()
117 verify(mDevice, times(i)).executeShellCommand(matches("screenrecord .*video.mp4")); in testScreenRecord()
120 .executeShellCommand( in testScreenRecord()
131 verify(mDevice, times(i)).executeShellCommand(eq("pidof screenrecord")); in testScreenRecord()
132 verify(mDevice, times(i)).executeShellCommand(matches("kill -2 1234")); in testScreenRecord()
179 .executeShellCommand(matches("^.*[^1]-video.*.mp4$")); in testScreenRecord_multipleTests()
184 .executeShellCommand(endsWith(String.format("%d-video.mp4", i + 1))); in testScreenRecord_multipleTests()
189 .executeShellCommand(endsWith(String.format("%d-video%d.mp4", i + 1, p))); in testScreenRecord_multipleTests()
/platform_testing/libraries/collectors-helper/jank/test/src/com/android/helpers/
DJankCollectionHelperTest.java296 when(mUiDevice.executeShellCommand(cmd)).thenThrow(new RuntimeException()); in testCollect_delayExceptions_onReset()
308 .executeShellCommand(String.format(GFXINFO_COMMAND_RESET, "pkg1")); in testCollect_delayExceptions_onReset()
310 .executeShellCommand(String.format(GFXINFO_COMMAND_RESET, "pkg2")); in testCollect_delayExceptions_onReset()
312 .executeShellCommand(String.format(GFXINFO_COMMAND_RESET, "pkg3")); in testCollect_delayExceptions_onReset()
324 when(mUiDevice.executeShellCommand(cmd)).thenThrow(new RuntimeException()); in testCollect_delayExceptions_onGet()
337 .executeShellCommand(String.format(GFXINFO_COMMAND_RESET, "pkg1")); in testCollect_delayExceptions_onGet()
339 .executeShellCommand(String.format(GFXINFO_COMMAND_RESET, "pkg2")); in testCollect_delayExceptions_onGet()
341 .executeShellCommand(String.format(GFXINFO_COMMAND_RESET, "pkg3")); in testCollect_delayExceptions_onGet()
343 .executeShellCommand(String.format(GFXINFO_COMMAND_GET, "pkg1")); in testCollect_delayExceptions_onGet()
345 .executeShellCommand(String.format(GFXINFO_COMMAND_GET, "pkg2")); in testCollect_delayExceptions_onGet()
[all …]
DSfStatsCollectionHelperTest.java258 when(mUiDevice.executeShellCommand(SFSTATS_COMMAND_ENABLE_AND_CLEAR)).thenReturn(""); in mockEnableAndClearCommand()
262 when(mUiDevice.executeShellCommand(SFSTATS_COMMAND_DUMP)).thenReturn(SFSTATS_DUMP); in mockDumpCommand()
266 when(mUiDevice.executeShellCommand(SFSTATS_COMMAND_DISABLE_AND_CLEAR)).thenReturn(""); in mockDisableAndClearCommand()
/platform_testing/libraries/collectors-helper/perfetto/src/com/android/helpers/
DPerfettoHelper.java87 String output = mUIDevice.executeShellCommand(String.format(REMOVE_CMD, in startCollecting()
100 String startOutput = mUIDevice.executeShellCommand(perfettoCmd); in startCollecting()
153 String stopOutput = mUIDevice.executeShellCommand(PERFETTO_STOP_CMD); in stopPerfetto()
177 String perfettoProcId = mUIDevice.executeShellCommand(PERFETTO_PROC_ID_CMD); in isPerfettoRunning()
213 String moveResult = mUIDevice.executeShellCommand(String.format( in copyFileOutput()
/platform_testing/libraries/collectors-helper/simpleperf/src/com/android/helpers/
DSimpleperfHelper.java69 uiDevice.executeShellCommand( in startCollecting()
125 String stopOutput = mUiDevice.executeShellCommand(SIMPLEPERF_STOP_CMD); in stopSimpleperf()
147 String simpleperfProcId = mUiDevice.executeShellCommand(SIMPLEPERF_PROC_ID_CMD); in isSimpleperfRunning()
185 mUiDevice.executeShellCommand( in copyFileOutput()
/platform_testing/libraries/collectors-helper/memory/src/com/android/helpers/
DGarbageCollectionHelper.java80 String pidofOutput = mUiDevice.executeShellCommand( in garbageCollect()
83 mUiDevice.executeShellCommand(String.format(GC_CMD, pidofOutput)); in garbageCollect()
/platform_testing/libraries/collectors-helper/power/src/com/android/helpers/
DPwrStatsUtilHelper.java63 output = executeShellCommand("pwrstats_util -d " + mLogFile.getAbsolutePath()); in startCollecting()
79 executeShellCommand("kill -INT " + mUtilPid); in stopCollecting()
102 protected String executeShellCommand(String command) throws IOException { in executeShellCommand() method in PwrStatsUtilHelper
108 return mDevice.executeShellCommand(command); in executeShellCommand()
/platform_testing/tests/functional/applinktests/src/com/android/functional/applinktests/
DAppLinkTests.java204 executeShellCommand("pm clear " + TEST_PKG_NAME); in tearDown()
205 executeShellCommand("pm clear " + YOUTUBE_PKG_NAME); in tearDown()
206 executeShellCommand("pm set-app-link " + TEST_PKG_NAME + " undefined"); in tearDown()
207 executeShellCommand("pm set-app-link " + YOUTUBE_PKG_NAME + " always"); in tearDown()
216 String out = executeShellCommand(String.format( in openLink()
250 return executeShellCommand(String.format("pm get-app-link %s", pkgName)); in getAppLink()
255 executeShellCommand(String.format("pm set-app-link %s %s", pkgName, valueToBeSet)); in setAppLink()
259 private String executeShellCommand(String command) { in executeShellCommand() method in AppLinkTests
263 ParcelFileDescriptor pfd = mUiAutomation.executeShellCommand(command); in executeShellCommand()
/platform_testing/libraries/collectors-helper/perfetto/test/src/com/android/helpers/tests/
DPerfettoHelperTest.java60 uiDevice.executeShellCommand(String.format(REMOVE_CMD, "/data/local/tmp/out.pb")); in teardown()
123 String[] fileStats = uiDevice.executeShellCommand(String.format( in testPerfettoSuccess()
138 String[] fileStats = uiDevice.executeShellCommand(String.format( in testTextProtoConfigSuccess()
/platform_testing/libraries/collectors-helper/power/test/src/com/android/helpers/
DPwrStatsUtilHelperTest.java58 doReturn(metric_output).when(mHelper).executeShellCommand(matches("kill -INT \\d+")); in successfulRun()
59 doReturn(pid_output).when(mHelper).executeShellCommand(matches("pwrstats_util -d .*")); in successfulRun()
/platform_testing/libraries/collectors-helper/simpleperf/test/src/com/android/helpers/tests/
DSimpleperfHelperTest.java56 uiDevice.executeShellCommand(String.format(REMOVE_CMD, "/data/local/tmp/perf.data")); in teardown()
89 uiDevice.executeShellCommand( in testSimpleperfSuccess()
/platform_testing/libraries/device-collectors/src/main/java/android/device/collectors/
DScreenRecordCollector.java171 .executeShellCommand( in run()
184 String[] pids = getDevice().executeShellCommand("pidof screenrecord").split(" "); in cancel()
191 getDevice().executeShellCommand(String.format("kill -2 %s", pid)); in cancel()
/platform_testing/libraries/collectors-helper/jank/src/com/android/helpers/
DBinderCollectionHelper.java73 getUiAutomation().executeShellCommand(TRACE_IPC_COMMAND_START).checkError(); in startCollecting()
87 .executeShellCommand(String.format(TRACE_IPC_COMMAND_STOP, TRACE_FILE_PATH)) in getMetrics()
93 .executeShellCommand( in getMetrics()
/platform_testing/tests/perf/PerfTransitionTest/src/com/android/apptransition/tests/
DLatencyTests.java183 mDevice.executeShellCommand(FINGERPRINT_WAKE_FAKE_COMMAND); in testFingerprintWakeAndUnlock()
213 mDevice.executeShellCommand(TURN_ON_SCREEN_COMMAND); in testScreenTurnOn()
269 mDevice.executeShellCommand(String.format(AM_START_COMMAND_TEMPLATE, in testRotationLatency()
310 mDevice.executeShellCommand(String.format(AM_START_COMMAND_TEMPLATE, in testAppToRecents()
339 mDevice.executeShellCommand(String.format(AM_START_COMMAND_TEMPLATE, in testSettingsSearch()
/platform_testing/tests/perf/PowerPerfTest/src/com/android/powerperf/tests/
DPowerPerfTest.java49 String result = getUiDevice().executeShellCommand(mScriptFilePath); in testPowerPerf()

123