SuiteResultReporter

public class SuiteResultReporter
extends CollectingTestListener

java.lang.Object
   ↳ com.android.tradefed.result.CollectingTestListener
     ↳ com.android.tradefed.result.suite.SuiteResultReporter


收集整个套件调用的测试结果,并输出最终结果。

摘要

嵌套类

class SuiteResultReporter.ModulePrepTimes

用于在一个模块的准备和拆解时间段内的对象持有器。 

字段

public static final String SUITE_REPORTER_SOURCE

公共构造函数

SuiteResultReporter()

公共方法

int getCompleteModules()
long getFailedTests()
getModulesAbi()

返回模块 ABI 的映射:

long getPassedTests()
TestSummary getSummary()
int getTotalModules()
long getTotalTests()
void invocationEnded(long elapsedTime)

报告调用已终止,无论是成功终止还是因某种错误条件而终止。

void invocationStarted(IInvocationContext context)

报告测试调用的开始。

void testModuleStarted(IInvocationContext moduleContext)

报告模块运行的开始时间。

受保护的方法

long getCurrentTime()
long getEndTime()

返回调用的结束时间。

long getStartTime()

返回调用的开始时间。

字段

SUITE_REPORTER_SOURCE

public static final String SUITE_REPORTER_SOURCE

公共构造函数

SuiteResultReporter

public SuiteResultReporter ()

公共方法

getCompleteModules

public int getCompleteModules ()

返回
int

getFailedTests

public long getFailedTests ()

返回
long

getModulesAbi

public  getModulesAbi ()

返回模块 ABI 的映射:

返回

getPassedTests

public long getPassedTests ()

返回
long

getSummary

public TestSummary getSummary ()

返回
TestSummary

getTotalModules

public int getTotalModules ()

返回
int

getTotalTests

public long getTotalTests ()

返回
long

invocationEnded

public void invocationEnded (long elapsedTime)

报告调用已终止,无论是成功终止还是因某种错误条件而终止。

将由 TradeFederation 框架自动调用。

参数
elapsedTime long:调用的经过时间(以毫秒为单位)

invocationStarted

public void invocationStarted (IInvocationContext context)

报告测试调用的开始。

将由 TradeFederation 框架自动调用。报告程序需要替换此方法才能支持多设备报告。

参数
context IInvocationContext:调用相关信息

testModuleStarted

public void testModuleStarted (IInvocationContext moduleContext)

报告模块运行的开始时间。此回调与 testModuleEnded() 相关联,在序列中是可选的。它仅在使用模块(基于套件的运行程序)的运行期间使用。

参数
moduleContext IInvocationContext:模块的 IInvocationContext

受保护的方法

getCurrentTime

protected long getCurrentTime ()

返回
long

getEndTime

protected long getEndTime ()

返回调用的结束时间。

返回
long

getStartTime

protected long getStartTime ()

返回调用的开始时间。

返回
long