IShardableTest
public
interface
IShardableTest
implements
IRemoteTest
com.android.tradefed.testtype.IShardableTest |
A IRemoteTest
that can be split into separately executable sub-tests. The splitting into
sub-tests is expected to be deterministic and each sub-test should be independent in order to
allow for execution of different shards on different hosts.
Summary
Public methods | |
---|---|
default
|
split(Integer shardCountHint, TestInformation testInfo)
Alternative version of |
default
|
split()
Shard the test into separately runnable chunks. |
default
|
split(int shardCountHint)
Alternative version of |
Public methods
split
publicsplit (Integer shardCountHint, TestInformation testInfo)
Alternative version of split(int)
which also provides a TestInformation
which contains early info from the parent creating the shards. It is useful if things like
device or build information need to be accessed during sharding.
Parameters | |
---|---|
shardCountHint |
Integer : the attempted shard count. |
testInfo |
TestInformation : The parent TestInformation |
Returns | |
---|---|
|
a collection of subtests to be executed separately or null if test is
not currently shardable |
split
publicsplit ()
Shard the test into separately runnable chunks.
This must be deterministic and always return the same list of IRemoteTest
s for the
same input.
This will be called before test execution, so injected dependencies (such as the ITestDevice
for IDeviceTest
s) may be null.
Returns | |
---|---|
|
a collection of subtests to be executed separately or null if test is
not currently shardable |
split
publicsplit (int shardCountHint)
Alternative version of split()
which also provides the shardCount that is attempted
to be run. This is useful for some test runner that cannot arbitrarily decide sometimes.
Parameters | |
---|---|
shardCountHint |
int : the attempted shard count. |
Returns | |
---|---|
|
a collection of subtests to be executed separately or null if test is
not currently shardable |