Home
last modified time | relevance | path

Searched refs:CommandStatus (Results 1 – 25 of 64) sorted by relevance

123

/tools/tradefederation/core/src/com/android/tradefed/util/
DCommandResult.java24 private CommandStatus mCmdStatus = CommandStatus.TIMED_OUT;
39 public CommandResult(CommandStatus status) { in CommandResult()
48 public CommandStatus getStatus() { in getStatus()
52 public void setStatus(CommandStatus status) { in setStatus()
DRunUtil.java153 CommandStatus status = runTimed(timeout, osRunnable, true); in runTimedCmd()
181 if (CommandStatus.SUCCESS.equals(result.getStatus())) { in runTimedCmdRetry()
239 CommandStatus status = runTimed(timeout, osRunnable, true); in runTimedCmdWithInput()
252 CommandStatus status = runTimed(timeout, osRunnable, false); in runTimedCmdSilently()
267 if (CommandStatus.SUCCESS.equals(result.getStatus())) { in runTimedCmdSilentlyRetry()
318 public CommandStatus runTimed(long timeout, IRunUtil.IRunnableResult runnable, in runTimed()
355 CommandStatus status = runThread.getStatus(); in runTimed()
356 if (CommandStatus.TIMED_OUT.equals(status) || CommandStatus.EXCEPTION.equals(status)) { in runTimed()
371 if (runTimed(opTimeout, runnable, true) == CommandStatus.SUCCESS) { in runTimedRetry()
388 if (runTimed(opTimeout, runnable, true) == CommandStatus.SUCCESS) { in runFixedTimedRetry()
[all …]
DCommandStatus.java21 public enum CommandStatus { enum
/tools/tradefederation/core/tests/src/com/android/tradefed/device/
DAndroidDebugBridgeWrapperTest.java21 import com.android.tradefed.util.CommandStatus;
53 res.setStatus(CommandStatus.SUCCESS); in testAdbVersionParsing()
69 res.setStatus(CommandStatus.SUCCESS); in testAdbVersionParsing_altFormat()
88 res.setStatus(CommandStatus.FAILED); in testAdbVersionParse_runFail()
104 res.setStatus(CommandStatus.SUCCESS); in testAdbVersionParsing_partial()
120 res.setStatus(CommandStatus.SUCCESS); in testAdbVersionParsing_parseFail()
DRemoteAndroidDeviceTest.java20 import com.android.tradefed.util.CommandStatus;
77 adbResult.setStatus(CommandStatus.SUCCESS); in testAdbConnect()
80 adbResultConfirmation.setStatus(CommandStatus.SUCCESS); in testAdbConnect()
97 adbResult.setStatus(CommandStatus.SUCCESS); in testAdbConnect_fails()
115 adbResult.setStatus(CommandStatus.SUCCESS); in testAdbConnect_fails_confirmation()
131 adbResult.setStatus(CommandStatus.SUCCESS); in testAdbDisconnect()
144 adbResult.setStatus(CommandStatus.FAILED); in testAdbDisconnect_fails()
DFastbootHelperTest.java20 import com.android.tradefed.util.CommandStatus;
112 CommandResult fakeRes = new CommandResult(CommandStatus.FAILED); in testIsFastbootAvailable_oldVersion()
125 CommandResult fakeRes = new CommandResult(CommandStatus.FAILED); in testIsFastbootAvailable_noBinary()
138 CommandResult fakeRes = new CommandResult(CommandStatus.FAILED); in testGetDevice_fail()
157 CommandResult fakeRes = new CommandResult(CommandStatus.SUCCESS); in testExecuteCommand()
170 CommandResult fakeRes = new CommandResult(CommandStatus.FAILED); in testExecuteCommand_fail()
DWaitDeviceRecoveryTest.java24 import com.android.tradefed.util.CommandStatus;
135 result.setStatus(CommandStatus.SUCCESS); in testRecoverDevice_fastboot()
161 andReturn(new CommandResult(CommandStatus.SUCCESS)); in testRecoverDeviceBootloader_fastboot()
169 andReturn(new CommandResult(CommandStatus.SUCCESS)); in testRecoverDeviceBootloader_fastboot()
187 andReturn(new CommandResult(CommandStatus.SUCCESS)); in testRecoverDeviceBootloader_unavailable()
195 andReturn(new CommandResult(CommandStatus.SUCCESS)); in testRecoverDeviceBootloader_unavailable()
/tools/tradefederation/core/tests/src/com/android/tradefed/util/
DRunUtilFuncTest.java62 assertEquals(CommandStatus.TIMED_OUT, RunUtil.getDefault().runTimed(SHORT_TIMEOUT_MS, in testRunTimed_timeout()
104 CommandStatus.SUCCESS.equals(result.getStatus())); in testRunTimedCmd_repeatedOutput()
117 assertTrue(CommandStatus.SUCCESS.equals(result.getStatus())); in testRunTimedCmd_noTimeout()
147 CommandStatus.SUCCESS, in testRunTimedCmd_largeOutput()
170 CommandStatus.SUCCESS, in testUnsetEnvVariable()
178 assertEquals(CommandStatus.FAILED, result.getStatus()); in testUnsetEnvVariable()
194 CommandStatus.TIMED_OUT, in testRunTimedCmd_timeout()
DRunUtilTest.java104 assertEquals(CommandStatus.SUCCESS, in testRunTimed()
116 assertEquals(CommandStatus.FAILED, in testRunTimed_failed()
129 assertEquals(CommandStatus.EXCEPTION, in testRunTimed_exception()
139 assertEquals(CommandStatus.EXCEPTION, result.getStatus()); in testRunTimedCmd_failed()
151 assertEquals(CommandStatus.TIMED_OUT, result.getStatus()); in testRunTimedCmd_timeout()
214 public CommandStatus runTimed(long timeout, IRunUtil.IRunnableResult runnable, in testRunEscalatingTimedRetry_timeout()
218 return runnable.run() ? CommandStatus.SUCCESS : CommandStatus.FAILED; in testRunEscalatingTimedRetry_timeout()
220 return CommandStatus.EXCEPTION; in testRunEscalatingTimedRetry_timeout()
309 assertEquals(CommandStatus.SUCCESS, result.getStatus()); in testRuntimedCmd_withFileOutputStream()
336 assertEquals(CommandStatus.SUCCESS, result.getStatus()); in testRuntimedCmd_regularOutput_fileNull()
[all …]
DGCSFileDownloaderFuncTest.java59 CommandStatus.SUCCESS, in setUpBeforeClass()
73 CommandStatus.SUCCESS, in setUpBeforeClass()
85 CommandStatus.SUCCESS, in tearDownAfterClass()
90 CommandStatus.SUCCESS, in tearDownAfterClass()
/tools/tradefederation/core/tests/src/com/android/tradefed/targetprep/
DPythonVirtualenvPreparerTest.java30 import com.android.tradefed.util.CommandStatus;
55 .andReturn(new CommandResult(CommandStatus.SUCCESS)); in testInstallDeps_reqFile_success()
66 new CommandResult(CommandStatus.SUCCESS)); in testInstallDeps_depModule_success()
77 .andReturn(new CommandResult(CommandStatus.TIMED_OUT)); in testInstallDeps_reqFile_failure()
92 new CommandResult(CommandStatus.TIMED_OUT)); in testInstallDeps_depModule_failure()
DFastbootDeviceFlasherTest.java28 import com.android.tradefed.util.CommandStatus;
131 fastbootResult.setStatus(CommandStatus.SUCCESS); in testGetImageVersion()
148 fastbootResult.setStatus(CommandStatus.SUCCESS); in testGetCurrentSlot_fastboot()
191 fastbootInValidResult.setStatus(CommandStatus.SUCCESS); in testRetryGetVersionCommand()
198 fastbootValidResult.setStatus(CommandStatus.SUCCESS); in testRetryGetVersionCommand()
289 fastbootOutput.setStatus(CommandStatus.SUCCESS); in testWipeCache_exists()
301 fastbootOutput.setStatus(CommandStatus.SUCCESS); in testWipeCache_exists()
336 fastbootOutput.setStatus(CommandStatus.SUCCESS); in testWipeCache_not_exists()
360 fastbootOutput.setStatus(CommandStatus.SUCCESS); in testWipeCache_not_exists_error()
379 result.setStatus(CommandStatus.SUCCESS); in doTestFlashWithWipe()
[all …]
DPreloadedClassesPreparerTest.java25 import com.android.tradefed.util.CommandStatus;
76 result.setStatus(CommandStatus.SUCCESS); in testSetUp_RemoteSuccess()
104 result.setStatus(CommandStatus.SUCCESS); in testSetUp_LocalSuccess()
124 result.setStatus(CommandStatus.FAILED); in testSetUp_WriteFailure()
DDeviceFlashPreparerTest.java36 import com.android.tradefed.util.CommandStatus;
98 CommandStatus flashingStatus) { in setUp()
120 .andReturn(CommandStatus.SUCCESS).anyTimes(); in testSetup()
189 .andReturn(CommandStatus.SUCCESS).anyTimes(); in testSetup_buildError()
219 .andReturn(CommandStatus.EXCEPTION).anyTimes(); in testSetup_flashException()
DRunHostCommandTargetPreparerTest.java22 import com.android.tradefed.util.CommandStatus;
78 CommandResult result = new CommandResult(CommandStatus.SUCCESS); in testSetUp()
99 CommandResult result = new CommandResult(CommandStatus.SUCCESS); in testTearDown()
/tools/tradefederation/core/src/com/android/tradefed/device/
DRemoteAndroidDevice.java21 import com.android.tradefed.util.CommandStatus;
126 if (CommandStatus.SUCCESS.equals(result.getStatus()) && in adbTcpConnect()
136 } else if (CommandStatus.SUCCESS.equals(result.getStatus()) && in adbTcpConnect()
152 if (CommandStatus.SUCCESS.equals(resultConfirmation.getStatus()) && in confirmAdbTcpConnect()
177 return CommandStatus.SUCCESS.equals(result.getStatus()); in adbTcpDisconnect()
DFastbootHelper.java21 import com.android.tradefed.util.CommandStatus;
63 if (fastbootResult.getStatus() == CommandStatus.SUCCESS) { in isFastbootAvailable()
86 if (fastbootResult.getStatus().equals(CommandStatus.SUCCESS)) { in getDevices()
124 if (fastbootResult.getStatus() != CommandStatus.SUCCESS) { in executeCommand()
/tools/tradefederation/core/tests/src/com/android/tradefed/testtype/
DPythonUnitTestRunnerTest.java27 import com.android.tradefed.util.CommandStatus;
104 private CommandStatus getStatus() { in getStatus()
107 return CommandStatus.SUCCESS; in getStatus()
109 return CommandStatus.FAILED; in getStatus()
112 return CommandStatus.FAILED; in getStatus()
114 return CommandStatus.TIMED_OUT; in getStatus()
/tools/tradefederation/core/src/com/android/tradefed/targetprep/
DDeviceWiper.java26 import com.android.tradefed.util.CommandStatus;
56 if (r.getStatus() != CommandStatus.SUCCESS) { in doFormat()
71 if (r.getStatus() != CommandStatus.SUCCESS) { in performFastbootOp()
DIDeviceFlasher.java22 import com.android.tradefed.util.CommandStatus;
120 public CommandStatus getSystemFlashingStatus(); in getSystemFlashingStatus()
DPythonVirtualenvPreparer.java26 import com.android.tradefed.util.CommandStatus;
76 if (c.getStatus() != CommandStatus.SUCCESS) { in installDeps()
89 if (c.getStatus() != CommandStatus.SUCCESS) { in installDeps()
/tools/tradefederation/core/tests/src/com/android/tradefed/sandbox/
DSandboxConfigUtilTest.java26 import com.android.tradefed.util.CommandStatus;
65 result.setStatus(CommandStatus.SUCCESS); in testDumpVersion()
89 result.setStatus(CommandStatus.FAILED); in testDumpVersion_failed()
/tools/tradefederation/core/tests/src/com/android/tradefed/build/
DSdkBuildInfoTest.java19 import com.android.tradefed.util.CommandStatus;
56 result.setStatus(CommandStatus.SUCCESS); in testGetSdkTargets()
/tools/tradefederation/core/tests/src/com/android/tradefed/testtype/python/
DPythonBinaryHostTestTest.java27 import com.android.tradefed.util.CommandStatus;
73 res.setStatus(CommandStatus.SUCCESS); in testRun()
106 res.setStatus(CommandStatus.EXCEPTION); in testRunFail_exception()
139 res.setStatus(CommandStatus.FAILED); in testRunFail_failureOnly()
/tools/tradefederation/core/src/com/android/tradefed/sandbox/
DSandboxInvocationRunner.java24 import com.android.tradefed.util.CommandStatus;
53 if (!CommandStatus.SUCCESS.equals(result.getStatus())) { in prepareAndRun()

123