PushFilePreparer
public
class
PushFilePreparer
extends BaseTargetPreparer
implements
IAbiReceiver,
IDiscoverDependencies,
IInvocationContextReceiver
| java.lang.Object | ||
| ↳ | com.android.tradefed.targetprep.BaseTargetPreparer | |
| ↳ | com.android.tradefed.targetprep.PushFilePreparer | |
A ITargetPreparer that attempts to push any number of files from any host path to any
device path.
Should be performed *after* a new build is flashed, and *after* DeviceSetup is run (if enabled)
Summary
Public constructors | |
|---|---|
PushFilePreparer()
|
|
Public methods | |
|---|---|
IAbi
|
getAbi()
|
final
|
getPushSpecs(ITestDevice device)
Create the list of files to be pushed. |
boolean
|
isCleanUpEnabled()
|
|
reportDependencies()
|
File
|
resolveRelativeFilePath(IBuildInfo buildInfo, String fileName)
Resolve relative file path via |
void
|
setAbi(IAbi abi)
|
void
|
setInvocationContext(IInvocationContext invocationContext)
|
void
|
setUp(TestInformation testInfo)
|
boolean
|
shouldAbortOnFailure()
Whether or not to abort on push failure. |
boolean
|
shouldRemountSystem()
|
boolean
|
shouldRemountVendor()
|
void
|
tearDown(TestInformation testInfo, Throwable e)
|
Public constructors
PushFilePreparer
public PushFilePreparer ()
Public methods
getPushSpecs
public finalgetPushSpecs (ITestDevice device)
Create the list of files to be pushed.
| Parameters | |
|---|---|
device |
ITestDevice |
| Returns | |
|---|---|
|
|
| Throws | |
|---|---|
TargetSetupError |
|
isCleanUpEnabled
public boolean isCleanUpEnabled ()
| Returns | |
|---|---|
boolean |
|
reportDependencies
publicreportDependencies ()
| Returns | |
|---|---|
|
|
resolveRelativeFilePath
public File resolveRelativeFilePath (IBuildInfo buildInfo, String fileName)
Resolve relative file path via IBuildInfo and test cases directories.
| Parameters | |
|---|---|
buildInfo |
IBuildInfo: the build artifact information |
fileName |
String: relative file path to be resolved |
| Returns | |
|---|---|
File |
the file from the build info or test cases directories |
setInvocationContext
public void setInvocationContext (IInvocationContext invocationContext)
| Parameters | |
|---|---|
invocationContext |
IInvocationContext |
setUp
public void setUp (TestInformation testInfo)
| Parameters | |
|---|---|
testInfo |
TestInformation |
| Throws | |
|---|---|
BuildError |
|
DeviceNotAvailableException |
|
TargetSetupError |
|
shouldAbortOnFailure
public boolean shouldAbortOnFailure ()
Whether or not to abort on push failure.
| Returns | |
|---|---|
boolean |
|
shouldRemountSystem
public boolean shouldRemountSystem ()
| Returns | |
|---|---|
boolean |
|
shouldRemountVendor
public boolean shouldRemountVendor ()
| Returns | |
|---|---|
boolean |
|
tearDown
public void tearDown (TestInformation testInfo, Throwable e)
| Parameters | |
|---|---|
testInfo |
TestInformation |
e |
Throwable |
| Throws | |
|---|---|
DeviceNotAvailableException |
|