沙盒调用执行
public class SandboxedInvocationExecution
extends InvocationExecution
java.lang.Object | ||
↳ | com.android.tradefed.invoker.InitationExecution | |
↳ | com.android.tradefed.invoker.sandbox.SandboxedInitationExecution |
调用的特殊沙箱执行:这是当我们在沙箱内运行命令时的 InvocationExection。该构建应该已经在上下文中可用。
概括
公共构造函数 | |
---|---|
SandboxedInvocationExecution () |
公共方法 | |
---|---|
void | cleanUpBuilds ( IInvocationContext context, IConfiguration config) 执行 build_provider 清理步骤。 |
boolean | fetchBuild ( TestInformation testInfo, IConfiguration config, IRescheduler rescheduler, ITestInvocationListener listener) 执行调用的 build_provider 步骤。 |
受保护的方法 | |
---|---|
getLabPreparersToRun ( IConfiguration config, String deviceName) 检索要在此设备上运行的实验室准备器列表。 | |
getTargetPreparersToRun ( IConfiguration config, String deviceName) 检索要在此设备上运行的目标准备器的列表。 | |
void | logHostAdb ( IConfiguration config, ITestLogger logger) 从 $TMPDIR/adb.$UID.log 收集日志。 |
公共构造函数
沙盒调用执行
public SandboxedInvocationExecution ()
公共方法
清理构建
public void cleanUpBuilds (IInvocationContext context, IConfiguration config)
执行 build_provider 清理步骤。与构建获取相关。
参数 | |
---|---|
context | IInvocationContext :调用的IInvocationContext 。 |
config | IConfiguration :本次测试运行的IConfiguration 。 |
获取构建
public boolean fetchBuild (TestInformation testInfo, IConfiguration config, IRescheduler rescheduler, ITestInvocationListener listener)
执行调用的 build_provider 步骤。
参数 | |
---|---|
testInfo | TestInformation :调用的TestInformation 。 |
config | IConfiguration :本次测试运行的IConfiguration 。 |
rescheduler | IRescheduler : IRescheduler ,用于重新安排调用的部分以便在另一个资源上执行 |
listener | ITestInvocationListener :报告构建下载失败的ITestInvocation 。 |
退货 | |
---|---|
boolean | 如果我们成功下载了构建版本,则为 true,否则为 false。 |
投掷 | |
---|---|
BuildRetrievalError | |
DeviceNotAvailableException |
受保护的方法
getLabPreparersToRun
protectedgetLabPreparersToRun (IConfiguration config, String deviceName)
检索要在此设备上运行的实验室准备器列表。
在沙箱类中重写,以限制实验室准备者在沙箱子项内运行
参数 | |
---|---|
config | IConfiguration |
deviceName | String |
退货 | |
---|---|
getTargetPreparersToRun
protectedgetTargetPreparersToRun (IConfiguration config, String deviceName)
检索要在此设备上运行的目标准备器的列表。
在沙箱类中重写,以限制实验室准备者在沙箱子项内运行
参数 | |
---|---|
config | IConfiguration |
deviceName | String |
退货 | |
---|---|
日志主机Adb
protected void logHostAdb (IConfiguration config, ITestLogger logger)
从 $TMPDIR/adb.$UID.log 收集日志。
参数 | |
---|---|
config | IConfiguration |
logger | ITestLogger |