报告通过测试

public class ReportPassedTests
extends CollectingTestListener implements IConfigurationReceiver , ISupportGranularResults

java.lang.Object
com.android.tradefed.result.CollectingTestListener
com.android.tradefed.result.ReportPassedTests


在文件中报告可能的过滤器以排除通过的测试。

概括

公共构造函数

ReportPassedTests ()

公共方法

void invocationEnded (long elapsedTime)

报告调用已终止,无论是成功终止还是由于某些错误情况。

void invocationFailed ( FailureDescription failure)

报告由于某些错误情况导致的不完整调用。

void invocationStarted ( IInvocationContext context)

报告测试调用的开始。

void setConfiguration ( IConfiguration configuration)

注入正在使用的IConfiguration

void setLogger ( ITestLogger logger)
boolean supportGranularResults ()

如果 reporter 支持粒度结果,则返回 True,否则返回 false。

void testModuleEnded ()

报告模块运行结束。

void testModuleStarted ( IInvocationContext moduleContext)

报告模块运行的开始。

void testRunEnded (long elapsedTime, runMetrics) testRunEnded (long elapsedTime, runMetrics)

报告测试运行结束。

公共构造函数

报告通过测试

public ReportPassedTests ()

公共方法

调用结束

public void invocationEnded (long elapsedTime)

报告调用已终止,无论是成功终止还是由于某些错误情况。

将由 TradeFederation 框架自动调用。

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

调用失败

public void invocationFailed (FailureDescription failure)

报告由于某些错误情况导致的不完整调用。

将由 TradeFederation 框架自动调用。

参数
failure FailureDescription :描述失败原因的FailureDescription

调用开始

public void invocationStarted (IInvocationContext context)

报告测试调用的开始。

将由 TradeFederation 框架自动调用。记者需要覆盖此方法以支持多设备报告。

参数
context IInvocationContext :有关调用的信息

设置配置

public void setConfiguration (IConfiguration configuration)

注入正在使用的IConfiguration

参数
configuration IConfiguration

设置记录器

public void setLogger (ITestLogger logger)

参数
logger ITestLogger

支持粒度结果

public boolean supportGranularResults ()

如果 reporter 支持粒度结果,则返回 True,否则返回 false。

退货
boolean

测试模块结束

public void testModuleEnded ()

报告模块运行结束。

测试模块启动

public void testModuleStarted (IInvocationContext moduleContext)

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

参数
moduleContext IInvocationContext :模块的IInvocationContext

测试运行结束

public void testRunEnded (long elapsedTime, 
                 runMetrics)

报告测试运行结束。 FIXME: 我们不能有两个不同类型的 Map<> 接口,所以我们必须在这里使用 HashMap。

参数
elapsedTime long :设备报告经过的时间,以毫秒为单位

runMetrics :在测试运行结束时使用Metric报告的键值对。