Home
last modified time | relevance | path

Searched refs:command (Results 1 – 25 of 232) sorted by relevance

12345678910

/tools/tradefederation/core/src/com/android/tradefed/util/
DGCSBucketUtil.java161 List<String> command = new ArrayList<>(); in copy() local
163 command.add(GSUTIL); in copy()
166 command.add(FLAG_PARALLEL); in copy()
169 command.add(CMD_COPY); in copy()
172 command.add(FLAG_RECURSIVE); in copy()
176 command.add(FLAG_NO_CLOBBER); in copy()
179 command.add(source); in copy()
180 command.add(dest); in copy()
182 String[] commandAsStr = command.toArray(new String[0]); in copy()
271 List<String> command = new ArrayList<>(); in makeBucket() local
[all …]
DRunUtil.java20 import com.android.tradefed.command.CommandInterrupter;
143 public CommandResult runTimedCmd(final long timeout, final String... command) { in runTimedCmd() argument
144 return runTimedCmd(timeout, null, null, command); in runTimedCmd()
152 OutputStream stderr, final String... command) { in runTimedCmd() argument
153 RunnableResult osRunnable = createRunnableResult(stdout, stderr, command); in runTimedCmd()
166 OutputStream stdout, OutputStream stderr, String... command) { in createRunnableResult() argument
169 createProcessBuilder(command), in createRunnableResult()
179 long timeout, long retryInterval, int attempts, String... command) { in runTimedCmdRetry() argument
183 result = runTimedCmd(timeout, command); in runTimedCmdRetry()
193 private synchronized ProcessBuilder createProcessBuilder(String... command) { in createProcessBuilder() argument
[all …]
DIRunUtil.java20 import com.android.tradefed.command.CommandScheduler;
102 public CommandResult runTimedCmd(final long timeout, final String... command); in runTimedCmd() argument
116 final long timeout, OutputStream stdout, OutputStream stderr, final String... command); in runTimedCmd() argument
129 int attempts, final String... command); in runTimedCmdRetry() argument
140 public CommandResult runTimedCmdSilently(final long timeout, final String... command); in runTimedCmdSilently() argument
154 int attempts, final String... command); in runTimedCmdSilentlyRetry() argument
165 CommandResult runTimedCmdWithInput(long timeout, String input, String... command); in runTimedCmdWithInput() argument
176 CommandResult runTimedCmdWithInput(long timeout, String input, List<String> command); in runTimedCmdWithInput() argument
189 long timeout, @Nullable File inputRedirect, String... command); in runTimedCmdWithInputRedirect() argument
200 public Process runCmdInBackground(String... command) throws IOException; in runCmdInBackground() argument
[all …]
DSimplePerfUtil.java93 public SimplePerfResult executeCommand(String command) throws DeviceNotAvailableException { in executeCommand() argument
94 String output = mDevice.executeShellCommand(commandStringPreparer(command)); in executeCommand()
109 public void executeCommand(String command, IShellOutputReceiver receiver) in executeCommand() argument
111 mDevice.executeShellCommand(commandStringPreparer(command), receiver); in executeCommand()
131 public void executeCommand(String command, IShellOutputReceiver receiver, in executeCommand() argument
134 mDevice.executeShellCommand(commandStringPreparer(command), receiver, in executeCommand()
138 protected String commandStringPreparer(String command) { in commandStringPreparer() argument
139 if (command == null) { in commandStringPreparer()
140 command = ""; in commandStringPreparer()
142 return commandPrependPreparer().toString() + command; in commandStringPreparer()
/tools/test/connectivity/acts/framework/acts/libs/proc/
Djob.py76 command=[], argument
94 self.command = command
107 self.command, self._raw_stdout, self._raw_stderr,
112 def run(command, argument
142 command,
146 shell=not isinstance(command, list))
159 command=command,
169 logging.error("Command %s with %s timeout setting timed out", command,
179 def run_async(command, env=None): argument
198 command,
[all …]
Dprocess.py50 def __init__(self, command, **kwargs): argument
57 if not kwargs.get('shell', False) and isinstance(command, str):
58 command = shlex.split(command)
59 self._command = command
222 def __start_process(command, **kwargs): argument
226 'Starting command "%s" with kwargs %s', command, kwargs)
227 return subprocess.Popen(command, **kwargs)
238 command = self._command
240 self._process = self.__start_process(command,
257 command = retry_value
/tools/test/connectivity/acts/framework/acts/controllers/buds_lib/
Db29_lib.py110 command = '--serial={}'.format(self.port)
111 debug_bridge_process = self._send_command(command=command)
144 def _send_command(self, command): argument
152 '{} {} {}'.format(DEBUG_BRIDGE, '--rpc_port=-1', command),
170 command = '--serial=%s --debug_spi=dfu --sqif_partition=8' % self.port
171 debug_bridge_process = self._send_command(command=command)
192 command = '--serial={} --ping={}'.format(self.port, component)
193 debug_bridge_process = self._send_command(command=command)
213 command = '--serial={} --charger_reset'.format(self.port)
214 reset_charger_process = self._send_command(command=command)
/tools/test/connectivity/tools/lab/utils/
Djob.py74 command=[], argument
92 self.command = command
105 self.command, self._raw_stdout, self._raw_stderr,
110 def run(command, argument
140 command,
144 shell=not isinstance(command, list))
157 command=command,
167 logging.error("Command %s with %s timeout setting timed out", command,
177 def run_async(command, env=None): argument
196 command,
[all …]
/tools/tradefederation/core/src/com/android/tradefed/device/cloud/
DLaunchCvdHelper.java46 List<String> command = new ArrayList<>(); in createSimpleDeviceCommand() local
47 command.add("sudo -u " + username); in createSimpleDeviceCommand()
48 command.add("/home/" + username + "/bin/launch_cvd"); in createSimpleDeviceCommand()
49 command.add("-data_policy"); in createSimpleDeviceCommand()
51 command.add("always_create"); in createSimpleDeviceCommand()
53 command.add("create_if_missing"); in createSimpleDeviceCommand()
56 command.add("-blank_data_image_mb"); in createSimpleDeviceCommand()
58 command.add("8000"); in createSimpleDeviceCommand()
60 command.add("-daemon"); in createSimpleDeviceCommand()
62 return command; in createSimpleDeviceCommand()
/tools/tradefederation/core/tests/src/com/android/tradefed/targetprep/
DRunCommandTargetPreparerTest.java68 final String command = "mkdir test"; in testSetUp() local
70 setter.setOptionValue("run-command", command); in testSetUp()
74 EasyMock.expect(mMockDevice.executeShellV2Command(EasyMock.eq(command))).andReturn(res); in testSetUp()
86 final String command = "mkdir test"; in testSetUp_withTimeout() local
88 setter.setOptionValue("run-command", command); in testSetUp_withTimeout()
95 EasyMock.eq(command), in testSetUp_withTimeout()
112 final String command = "mkdir test"; in testDisabled() local
114 setter.setOptionValue("run-command", command); in testDisabled()
128 final String command = "mkdir test"; in testTearDown() local
130 setter.setOptionValue("teardown-command", command); in testTearDown()
[all …]
DRunHostCommandTargetPreparerTest.java71 final String command = "command \t\t\t \t argument " + DEVICE_SERIAL_PLACEHOLDER; in testSetUp() local
75 optionSetter.setOptionValue("host-setup-command", command); in testSetUp()
93 final String command = "command \t\t\t \t argument " + DEVICE_SERIAL_PLACEHOLDER; in testSetUp_withWorkDir() local
98 optionSetter.setOptionValue("host-setup-command", command); in testSetUp_withWorkDir()
116 final String command = "command \t\t\t \t argument " + DEVICE_SERIAL_PLACEHOLDER; in testTearDown() local
120 optionSetter.setOptionValue("host-teardown-command", command); in testTearDown()
137 final String command = "command \t\t\t \t argument " + DEVICE_SERIAL; in testBgCommand() local
141 optionSetter.setOptionValue("host-background-command", command); in testBgCommand()
/tools/tradefederation/core/src/com/android/tradefed/targetprep/
DRunHostCommandTargetPreparer.java193 for (final String command : commands) { in runCommandList()
194 final CommandResult result = getRunUtil().runTimedCmd(mTimeout, command.split("\\s+")); in runCommandList()
199 command, result.getStdout()); in runCommandList()
204 command, result.getStdout(), result.getStderr()); in runCommandList()
207 CLog.e("Command %s timed out.", command); in runCommandList()
210 CLog.e("Exception occurred when running command %s.", command); in runCommandList()
225 String command = bgCommands.get(i); in runBgCommandList() local
226 CLog.d("About to run host background command: %s", command); in runBgCommandList()
230 Arrays.asList(command.split("\\s+")), in runBgCommandList()
233 CLog.e("Failed to run command: %s", command); in runBgCommandList()
[all …]
/tools/tradefederation/contrib/src/com/android/performance/tests/
DEmmcPerformanceTest.java146 String command = in runSequentialRead() local
149 runTest(SEQUENTIAL_READ_KEY, command, TestType.DD, true, iterations, listener, metrics); in runSequentialRead()
156 String command = in runSequentialWrite() local
159 runTest(SEQUENTIAL_WRITE_KEY, command, TestType.DD, false, iterations, listener, metrics); in runSequentialWrite()
167 String command = in runRandomRead() local
173 runTest(RANDOM_READ_KEY, command, TestType.RANDOM, true, iterations, listener, metrics); in runRandomRead()
180 String command = in runRandomWrite() local
186 runTest(RANDOM_WRITE_KEY, command, TestType.RANDOM, false, iterations, listener, metrics); in runRandomWrite()
203 String command, in runTest() argument
225 kbps = runDdIteration(command, simpleperfMetricsMap); in runTest()
[all …]
/tools/test/connectivity/acts/framework/acts/libs/ota/ota_runners/
Dota_runner_factory.py78 command = DEFAULT_OTA_COMMAND
80 command = config[ota_tool_class_name]
81 if type(command) is list:
83 if len(command) == 1:
84 command = command[0]
99 command)
106 command=DEFAULT_OTA_COMMAND, argument
123 ota_tool = ota_tool_factory.create(ota_tool_class_name, command)
/tools/tradefederation/contrib/src/com/android/uicd/tests/
DUiConductorTest.java342 List<String> command = new ArrayList<>(); in getCommand() local
343 command.add("java"); in getCommand()
344 command.add("-jar"); in getCommand()
345 command.add(jarFile.getAbsolutePath()); in getCommand()
347 command.add(OPTION_SYMBOL + INPUT_OPTION_SHORT_NAME); in getCommand()
348 command.add(getTestFilesArgsForUicdBin(TESTS_RELATIVE_PATH, testFileName)); in getCommand()
351 command.add(OPTION_SYMBOL + OUTPUT_OPTION_SHORT_NAME); in getCommand()
352 command.add(getOutFilesArgsForUicdBin(OUTPUT_RELATIVE_PATH + "/" + testId)); in getCommand()
355 command.add(OPTION_SYMBOL + MODE_OPTION_SHORT_NAME); in getCommand()
356 command.add(getPlaymodeArgForUicdBin()); in getCommand()
[all …]
/tools/test/connectivity/acts/framework/tests/libs/ota/ota_tools/
Dota_tool_factory_test.py22 def __init__(self, command): argument
23 self.command = command
32 MockOtaTool.__name__: lambda command: MockOtaTool(command),
45 MockOtaTool.__name__: lambda command: MockOtaTool(command),
/tools/tradefederation/core/src/com/android/tradefed/device/
DINativeDevice.java23 import com.android.tradefed.command.remote.DeviceDescriptor;
219 public void executeShellCommand(String command, IShellOutputReceiver receiver) in executeShellCommand() argument
238 public void executeShellCommand(String command, IShellOutputReceiver receiver, in executeShellCommand() argument
261 String command, in executeShellCommand() argument
277 public String executeShellCommand(String command) throws DeviceNotAvailableException; in executeShellCommand() argument
288 public CommandResult executeShellV2Command(String command) throws DeviceNotAvailableException; in executeShellV2Command() argument
300 public CommandResult executeShellV2Command(String command, File pipeAsInput) in executeShellV2Command() argument
313 public CommandResult executeShellV2Command(String command, OutputStream pipeToOutput) in executeShellV2Command() argument
329 String command, final long maxTimeoutForCommand, final TimeUnit timeUnit) in executeShellV2Command() argument
348 String command, in executeShellV2Command() argument
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/command/
DConsoleTest.java16 package com.android.tradefed.command;
24 import com.android.tradefed.command.Console.CaptureList;
217 String[] command = new String[] {"run", "command", "--arg", "value", "config.xml"}; in testRunCommand() local
226 Runnable runnable = trie.retrieve(captures, command); in testRunCommand()
227 assertNotNull(String.format("Console didn't match input %s", Arrays.toString(command)), in testRunCommand()
237 String[] command = new String[] {"run", "--arg", "value", "config.xml"}; in testRunCommand_shortcut() local
246 Runnable runnable = trie.retrieve(captures, command); in testRunCommand_shortcut()
247 assertNotNull(String.format("Console didn't match input %s", Arrays.toString(command)), in testRunCommand_shortcut()
260 String[] command = new String[] {"run", "command", "command", "--arg", "value", in testRunCommand_startsWithCommand() local
270 Runnable runnable = trie.retrieve(captures, command); in testRunCommand_startsWithCommand()
[all …]
/tools/test/connectivity/acts/framework/tests/controllers/sl4a_lib/
Dsl4a_manager_test.py207 command = 'ngo45hke3b4vie3mv5ni93,vfu3j'
208 sl4a_manager._SL4A_ROOT_FIND_PORT_CMD = command
211 self.assertEqual(manager._get_all_ports_command(), command)
222 command = 'ngo45hke3b4vie3mv5ni93,vfu3j'
223 sl4a_manager._SL4A_ROOT_FIND_PORT_CMD = command
226 self.assertEqual(manager._get_all_ports_command(), command)
237 command = 'ngo45hke3b4vie3mv5ni93,vfu3j'
238 sl4a_manager._SL4A_USER_FIND_PORT_CMD = command
241 self.assertEqual(manager._get_all_ports_command(), command)
418 def close(command): argument
[all …]
/tools/test/connectivity/acts/framework/acts/libs/ota/ota_tools/
Dota_tool_factory.py21 AdbSideloadOtaTool.__name__: lambda command: AdbSideloadOtaTool(command),
22 UpdateDeviceOtaTool.__name__: lambda command: UpdateDeviceOtaTool(command),
27 def create(ota_tool_class, command): argument
49 new_update_tool = _CONSTRUCTORS[ota_tool_class](command)
/tools/test/connectivity/acts/framework/acts/controllers/utils_lib/ssh/
Dconnection.py50 self.result.command, self.result.stdout, self.result.stderr)
155 command, argument
201 full_command = 'echo "CONNECTED: %s"; %s' % (identifier, command)
226 command=result.command,
277 self.run(command, timeout, ignore_status, env, io_encoding,
281 def run_async(self, command, env=None): argument
302 command = '(%s) < /dev/null > /dev/null 2>&1 & echo -n $!' % command
303 result = self.run(command, env=env)
/tools/test/connectivity/acts/tests/google/bt/
Drelay_tool.py142 if args.command:
143 if args.command[0] not in func_names:
145 (repr(args.command[0]), repr(func_names)), file=sys.stderr)
148 func = getattr(relay_device, args.command[0])
150 ret = func(*args.command[1:])
160 args.command[0], file=sys.stderr)
161 print_docstring(relay_device, args.command[0])
/tools/tradefederation/core/tests/src/com/android/tradefed/util/
DSimplePerfUtilTest.java46 String command = "ls -l"; in testCommandStringPreparerWithoutParams() local
47 String fullCommand = spu.commandStringPreparer(command); in testCommandStringPreparerWithoutParams()
48 Assert.assertEquals("simpleperf stat " + command, fullCommand); in testCommandStringPreparerWithoutParams()
53 String command = "sleep 10"; in testCommandStringPreparerWithParams() local
60 String fullCommand = spu.commandStringPreparer(command); in testCommandStringPreparerWithParams()
61 Assert.assertEquals("simpleperf record -e cpu-cycles:k --no-inherit perf.data " + command, in testCommandStringPreparerWithParams()
/tools/tradefederation/core/tests/src/com/android/tradefed/device/
DNativeDeviceTest.java39 import com.android.tradefed.command.remote.DeviceDescriptor;
350 public String executeShellCommand(String command) in testPullDir_nothingToDo()
394 public String executeShellCommand(String command) in testPullDir()
463 public String executeShellCommand(String command) in testPullDir_pullFail()
534 public String executeShellCommand(String command) in testPullDir_invalidPath()
1125 String command, IShellOutputReceiver receiver, in testGetBugreport_deviceUnavail()
1150 String command, IShellOutputReceiver receiver, in testGetBugreport_compatibility_deviceUnavail()
1175 String command, IShellOutputReceiver receiver, in testGetBugreport_deviceUnavail_fallback()
1219 String command, in testGetBugreportz()
1681 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testUnlockDevice()
[all …]
DTestDeviceTest.java258 private void setExecuteAdbCommandExpectations(CommandResult result, String command) in setExecuteAdbCommandExpectations() argument
262 EasyMock.eq(command))).andReturn(result); in setExecuteAdbCommandExpectations()
2578 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testCreateUserFlags()
2591 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testCreateUser_wrongOutput()
2635 public String executeShellCommand(String command) in testCreateUserNoThrow_wrongOutput()
2844 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testGetCurrentUser()
2867 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testGetCurrentUser_null()
2917 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testGetUserFlag()
2937 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testGetUserFlag_emptyReturn()
2956 public String executeShellCommand(String command) throws DeviceNotAvailableException { in testGetUserFlag_multiUser()
[all …]

12345678910