TestDeviceOptions

public class TestDeviceOptions
extends Object

java.lang.Object
   ↳ com.android.tradefed.device.TestDeviceOptions


Container for ITestDevice Options

Summary

Public constructors

TestDeviceOptions()

Public methods

int getAdbRecoveryTimeout()
long getAvailableTimeout()
String getConnCheckUrl()
Integer getCutoffBattery()
int getFastbootTimeout()
String getLogcatOptions()
long getMaxLogcatDataSize()

Get the approximate maximum size of a tmp logcat data to retain, in bytes.

long getOnlineTimeout()
List<String> getPostBootCommands()
int getRebootTimeout()
int getUnencryptRebootTimeout()
boolean getUseFastbootErase()
int getWifiAttempts()
int getWifiRetryWaitTime()
boolean isDisableKeyguard()

Check whether or not we should attempt to disable the keyguard once boot has completed

boolean isEnableAdbRoot()

Check whether adb root should be enabled on boot for this device

boolean isLogcatCaptureEnabled()
boolean isWifiExpoRetryEnabled()
void setAdbRecoveryTimeout(int adbRecoveryTimeout)
void setConnCheckUrl(String url)
void setCutoffBattery(int cutoffBattery)

set the minimum battery level to continue the invocation.

void setDisableKeyguard(boolean disableKeyguard)

Set whether or not we should attempt to disable the keyguard once boot has completed

void setEnableAdbRoot(boolean enableAdbRoot)

Set whether adb root should be enabled on boot for this device

void setFastbootTimeout(int fastbootTimeout)
void setLogcatOptions(String logcatOptions)

Set the options to be passed down to logcat

void setMaxLogcatDataSize(long maxLogcatDataSize)

Set the approximate maximum size of a tmp logcat to retain, in bytes

void setOnlineTimeout(long onlineTimeout)
void setRebootTimeout(int rebootTimeout)
void setUnencryptRebootTimeout(int unencryptRebootTimeout)
void setUseFastbootErase(boolean useFastbootErase)
void setWifiAttempts(int wifiAttempts)
boolean shouldDisableReboot()

Public constructors

TestDeviceOptions

TestDeviceOptions ()

Public methods

getAdbRecoveryTimeout

int getAdbRecoveryTimeout ()

Returns
int the timeout in msecs to boot into recovery mode.

getAvailableTimeout

long getAvailableTimeout ()

Returns
long the default time in ms to to wait for a device to be available.

getConnCheckUrl

String getConnCheckUrl ()

Returns
String the default URL to be used for connectivity tests.

getCutoffBattery

Integer getCutoffBattery ()

Returns
Integer the minimum battery level to continue the invocation.

getFastbootTimeout

int getFastbootTimeout ()

Returns
int the timeout to boot into fastboot mode in msecs.

getLogcatOptions

String getLogcatOptions ()

Returns
String the configured logcat options

getMaxLogcatDataSize

long getMaxLogcatDataSize ()

Get the approximate maximum size of a tmp logcat data to retain, in bytes.

Returns
long

getOnlineTimeout

long getOnlineTimeout ()

Returns
long the default time in ms to to wait for a device to be online.

getPostBootCommands

List<String> getPostBootCommands ()

Returns
List<String> a list of shell commands to run after reboots.

getRebootTimeout

int getRebootTimeout ()

Returns
int the timeout in msecs for the full system boot.

getUnencryptRebootTimeout

int getUnencryptRebootTimeout ()

Returns
int the timeout in msecs for the filesystem to be formatted and the device to reboot after unencryption.

getUseFastbootErase

boolean getUseFastbootErase ()

Returns
boolean whether to use fastboot erase instead of fastboot format to wipe partitions.

getWifiAttempts

int getWifiAttempts ()

Returns
int the default number of attempts to connect to wifi network.

getWifiRetryWaitTime

int getWifiRetryWaitTime ()

Returns
int the base wait time between wifi connect retries.

isDisableKeyguard

boolean isDisableKeyguard ()

Check whether or not we should attempt to disable the keyguard once boot has completed

Returns
boolean

isEnableAdbRoot

boolean isEnableAdbRoot ()

Check whether adb root should be enabled on boot for this device

Returns
boolean

isLogcatCaptureEnabled

boolean isLogcatCaptureEnabled ()

Returns
boolean true if background logcat capture is enabled

isWifiExpoRetryEnabled

boolean isWifiExpoRetryEnabled ()

Returns
boolean if the exponential retry strategy should be used.

setAdbRecoveryTimeout

void setAdbRecoveryTimeout (int adbRecoveryTimeout)

Parameters
adbRecoveryTimeout int: the timeout in msecs to boot into recovery mode.

setConnCheckUrl

void setConnCheckUrl (String url)

Parameters
url String

setCutoffBattery

void setCutoffBattery (int cutoffBattery)

set the minimum battery level to continue the invocation.

Parameters
cutoffBattery int

setDisableKeyguard

void setDisableKeyguard (boolean disableKeyguard)

Set whether or not we should attempt to disable the keyguard once boot has completed

Parameters
disableKeyguard boolean

setEnableAdbRoot

void setEnableAdbRoot (boolean enableAdbRoot)

Set whether adb root should be enabled on boot for this device

Parameters
enableAdbRoot boolean

setFastbootTimeout

void setFastbootTimeout (int fastbootTimeout)

Parameters
fastbootTimeout int: the timout in msecs to boot into fastboot mode.

setLogcatOptions

void setLogcatOptions (String logcatOptions)

Set the options to be passed down to logcat

Parameters
logcatOptions String

setMaxLogcatDataSize

void setMaxLogcatDataSize (long maxLogcatDataSize)

Set the approximate maximum size of a tmp logcat to retain, in bytes

Parameters
maxLogcatDataSize long

setOnlineTimeout

void setOnlineTimeout (long onlineTimeout)

Parameters
onlineTimeout long

setRebootTimeout

void setRebootTimeout (int rebootTimeout)

Parameters
rebootTimeout int: the timeout in msecs for the system to fully boot.

setUnencryptRebootTimeout

void setUnencryptRebootTimeout (int unencryptRebootTimeout)

Parameters
unencryptRebootTimeout int: the timeout in msecs for the filesystem to be formatted and the device to reboot after unencryption.

setUseFastbootErase

void setUseFastbootErase (boolean useFastbootErase)

Parameters
useFastbootErase boolean: whether to use fastboot erase instead of fastboot format to wipe partitions.

setWifiAttempts

void setWifiAttempts (int wifiAttempts)

Parameters
wifiAttempts int

shouldDisableReboot

boolean shouldDisableReboot ()

Returns
boolean if device reboot should be disabled