Google is committed to advancing racial equity for Black communities. See how.
本頁面由 Cloud Translation API 翻譯而成。
Switch to English

ProtoResultReporter

public abstract class ProtoResultReporter
extends Object implements ITestInvocationListener, ILogSaverListener, ISupportGranularResults

java.lang.Object
com.android.tradefed.result.proto.ProtoResultReporter


結果報告程序構建一個TestRecord protobuf,其中包含所有結果。應該擴展為處理processFinalProto(com.android.tradefed.result.proto.TestRecordProto.TestRecord)的最終原型。

摘要

公共建設者

ProtoResultReporter ()

公開方法

final void invocationEnded (long elapsedTime)
void invocationFailed (FailureDescription failure)
void invocationFailed (Throwable cause)
final void invocationStarted (IInvocationContext context)
final void logAssociation (String dataName, LogFile logFile)
void processFinalProto (TestRecordProto.TestRecord finalRecord)

處理所有結果的最終原型。

void processStartInvocation (TestRecordProto.TestRecord invocationStartRecord, IInvocationContext invocationContext)

發生invocationStarted(com.android.tradefed.invoker.IInvocationContext)之後處理部分調用測試記錄原型。

void processTestCaseEnded (TestRecordProto.TestRecord testCaseRecord)

在發生ITestLifeCycleReceiver.testEnded(com.android.tradefed.result.TestDescription, long, HashMap)之後處理最終的測試用例記錄原型。

void processTestCaseStarted (TestRecordProto.TestRecord testCaseStartedRecord)

testStarted(com.android.tradefed.result.TestDescription, long)發生後處理部分測試用例記錄原型。

void processTestModuleEnd (TestRecordProto.TestRecord moduleRecord)

testModuleEnded()發生後處理最終的模塊記錄原型。

void processTestModuleStarted (TestRecordProto.TestRecord moduleStartRecord)

testModuleStarted(com.android.tradefed.invoker.IInvocationContext)發生後處理部分模塊記錄原型。

void processTestRunEnded (TestRecordProto.TestRecord runRecord, boolean moduleInProgress)

ITestLifeCycleReceiver.testRunEnded(long, HashMap)發生後處理最終的運行記錄原型。

void processTestRunStarted (TestRecordProto.TestRecord runStartedRecord)

testRunStarted(String, int)發生後處理部分測試運行記錄原型。

boolean supportGranularResults ()
final void testAssumptionFailure (TestDescription test, String trace)
final void testAssumptionFailure (TestDescription test, FailureDescription failure)
final void testEnded (TestDescription test, long endTime, testMetrics) testEnded (TestDescription test, long endTime, testMetrics)
void testEnded (TestDescription test, testMetrics) testEnded (TestDescription test, testMetrics)
final void testFailed (TestDescription test, FailureDescription failure)
final void testFailed (TestDescription test, String trace)
final void testIgnored (TestDescription test)
final void testModuleEnded ()
final void testModuleStarted (IInvocationContext moduleContext)
final void testRunEnded (long elapsedTimeMillis, runMetrics) testRunEnded (long elapsedTimeMillis, runMetrics)
final void testRunFailed (FailureDescription failure)
final void testRunFailed (String errorMessage)
void testRunStarted (String runName, int testCount, int attemptNumber)
final void testRunStarted (String runName, int testCount)
void testRunStarted (String runName, int testCount, int attemptNumber, long startTime)
final void testStarted (TestDescription test, long startTime)
final void testStarted (TestDescription test)

公共建設者

ProtoResultReporter

public ProtoResultReporter ()

公開方法

調用結束

public final void invocationEnded (long elapsedTime)

參量
elapsedTime long

調用失敗

public void invocationFailed (FailureDescription failure)

參量
failure FailureDescription

調用失敗

public void invocationFailed (Throwable cause)

參量
cause Throwable

調用開始

public final void invocationStarted (IInvocationContext context)

參量
context IInvocationContext

logAssociation

public final void logAssociation (String dataName, 
                LogFile logFile)

參量
dataName String

logFile LogFile

processFinalProto

public void processFinalProto (TestRecordProto.TestRecord finalRecord)

處理所有結果的最終原型。

參量
finalRecord TestRecordProto.TestRecord :帶有所有調用結果的最終原型。

processStartInvocation

public void processStartInvocation (TestRecordProto.TestRecord invocationStartRecord, 
                IInvocationContext invocationContext)

發生invocationStarted(com.android.tradefed.invoker.IInvocationContext)之後處理部分調用測試記錄原型。

參量
invocationStartRecord TestRecordProto.TestRecord :在invocationStart之後填充的部分協議。

invocationContext IInvocationContext :調用IInvocationContext

processTestCaseEnded

public void processTestCaseEnded (TestRecordProto.TestRecord testCaseRecord)

在發生ITestLifeCycleReceiver.testEnded(com.android.tradefed.result.TestDescription, long, HashMap)之後處理最終的測試用例記錄原型。

參量
testCaseRecord TestRecordProto.TestRecord :表示測試案例的最終原型。

processTestCaseStarted

public void processTestCaseStarted (TestRecordProto.TestRecord testCaseStartedRecord)

testStarted(com.android.tradefed.result.TestDescription, long)發生後處理部分測試用例記錄原型。

參量
testCaseStartedRecord TestRecordProto.TestRecord :表示測試用例的部分原型。

processTestModuleEnd

public void processTestModuleEnd (TestRecordProto.TestRecord moduleRecord)

testModuleEnded()發生後處理最終的模塊記錄原型。

參量
moduleRecord TestRecordProto.TestRecord :表示模塊的最終原型。

processTestModuleStarted

public void processTestModuleStarted (TestRecordProto.TestRecord moduleStartRecord)

testModuleStarted(com.android.tradefed.invoker.IInvocationContext)發生後處理部分模塊記錄原型。

參量
moduleStartRecord TestRecordProto.TestRecord :表示模塊的部分原型。

processTestRunEnded

public void processTestRunEnded (TestRecordProto.TestRecord runRecord, 
                boolean moduleInProgress)

ITestLifeCycleReceiver.testRunEnded(long, HashMap)發生後處理最終的運行記錄原型。

參量
runRecord TestRecordProto.TestRecord :表示運行的最終原型。

moduleInProgress boolean :模塊是否在進行中。

processTestRunStarted

public void processTestRunStarted (TestRecordProto.TestRecord runStartedRecord)

在出現testRunStarted(String, int)之後處理部分測試運行記錄原型。

參量
runStartedRecord TestRecordProto.TestRecord :表示運行的部分原型。

supportGranularResults

public boolean supportGranularResults ()

退貨
boolean

testAssumptionFailure

public final void testAssumptionFailure (TestDescription test, 
                String trace)

參量
test TestDescription

trace String

testAssumptionFailure

public final void testAssumptionFailure (TestDescription test, 
                FailureDescription failure)

參量
test TestDescription

failure FailureDescription

testEnded

public final void testEnded (TestDescription test, 
                long endTime, 
                 testMetrics)

參量
test TestDescription

endTime long

testMetrics

testEnded

public void testEnded (TestDescription test, 
                 testMetrics)

參量
test TestDescription

testMetrics

測試失敗

public final void testFailed (TestDescription test, 
                FailureDescription failure)

參量
test TestDescription

failure FailureDescription

測試失敗

public final void testFailed (TestDescription test, 
                String trace)

參量
test TestDescription

trace String

testIgnored

public final void testIgnored (TestDescription test)

參量
test TestDescription

testModuleEnded

public final void testModuleEnded ()

testModuleStarted

public final void testModuleStarted (IInvocationContext moduleContext)

參量
moduleContext IInvocationContext

testRunEnded

public final void testRunEnded (long elapsedTimeMillis, 
                 runMetrics)

參量
elapsedTimeMillis long

runMetrics

testRunFailed

public final void testRunFailed (FailureDescription failure)

參量
failure FailureDescription

testRunFailed

public final void testRunFailed (String errorMessage)

參量
errorMessage String

testRunStarted

public void testRunStarted (String runName, 
                int testCount, 
                int attemptNumber)

參量
runName String

testCount int

attemptNumber int

testRunStarted

public final void testRunStarted (String runName, 
                int testCount)

參量
runName String

testCount int

testRunStarted

public void testRunStarted (String runName, 
                int testCount, 
                int attemptNumber, 
                long startTime)

參量
runName String

testCount int

attemptNumber int

startTime long

testStarted

public final void testStarted (TestDescription test, 
                long startTime)

參量
test TestDescription

startTime long

testStarted

public final void testStarted (TestDescription test)

參量
test TestDescription