ITestsZipInstaller

public interface ITestsZipInstaller

com.android.tradefed.targetprep.ITestsZipInstaller
Known Indirect Subclasses
DefaultTestsZipInstaller A default implementation of tests zip installer. 


Installs tests from a tests zip file (as outputted by the build system) on a device.

Summary

Public methods

abstract void deleteData(ITestDevice device)

Removes all of the files/directories from /data on the specified device, with the exception of those excluded by the skip list.

abstract void pushTestsZipOntoData(ITestDevice device, IDeviceBuildInfo deviceBuild)

Pushes the contents of the tests.zip file onto the device's data partition.

abstract void setDataWipeSkipList(String... skipList)

Sets the list of paths under /data to avoid clearing.

abstract void setDataWipeSkipList(Collection<String> skipList)

Sets the list of paths under /data to avoid clearing.

Public methods

deleteData

void deleteData (ITestDevice device)

Removes all of the files/directories from /data on the specified device, with the exception of those excluded by the skip list.

Implementation will stop the runtime on device. It is highly recommended to reboot the device upon completion of this method.

Parameters
device ITestDevice: The ITestDevice to act on

Throws
DeviceNotAvailableException
TargetSetupError

pushTestsZipOntoData

void pushTestsZipOntoData (ITestDevice device, 
                IDeviceBuildInfo deviceBuild)

Pushes the contents of the tests.zip file onto the device's data partition.

Parameters
device ITestDevice: the ITestDevice to flash, assumed to be in adb mode.

deviceBuild IDeviceBuildInfo: the IDeviceBuildInfo that contains the tests zip to flash

Throws
DeviceNotAvailableException
TargetSetupError
DeviceNotAvailableException

setDataWipeSkipList

void setDataWipeSkipList (String... skipList)

Sets the list of paths under /data to avoid clearing.

Parameters
skipList String: the list of directories to skip.

Note that the granularity of the skip list is direct children of /data.

setDataWipeSkipList

void setDataWipeSkipList (Collection<String> skipList)

Sets the list of paths under /data to avoid clearing.

Parameters
skipList Collection: the list of directories to skip.

Note that the granularity of the skip list is direct children of /data.