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

模塊監聽器

public class ModuleListener
extends CollectingTestListener

java.lang.Object
com.android.tradefed.result.CollectingTestListener
com.android.tradefed.testtype.suite.ModuleListener


偵聽器附加到每個模塊的每個IRemoteTest以便收集結果列表。

摘要

公共建設者

ModuleListener (ITestInvocationListener listener)

構造函數。

公開方法

boolean hasLastAttemptFailed ()

返回偵聽器的上一次重試會話是否失敗。

void logAssociation (String dataName, LogFile logFile)

void setCollectTestsOnly (boolean collectTestsOnly)

設置是否僅收集測試。

void setMarkTestsSkipped (boolean skip)

是否標記所有已跳過的測試用例。

void testAssumptionFailure (TestDescription test, String trace)
void testAssumptionFailure (TestDescription test, FailureDescription failure)
void testEnded (TestDescription test, long endTime, testMetrics) testEnded (TestDescription test, long endTime, testMetrics)

void testEnded (TestDescription test, testMetrics) testEnded (TestDescription test, testMetrics)

void testFailed (TestDescription test, FailureDescription failure)

void testFailed (TestDescription test, String trace)

void testIgnored (TestDescription test)
void testLog (String dataName, LogDataType dataType, InputStreamSource dataStream)

void testLogSaved (String dataName, LogDataType dataType, InputStreamSource dataStream, LogFile logFile)

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

void testRunFailed (FailureDescription failure)

void testRunFailed (String errorMessage)

void testRunStarted (String name, int numTests, int attemptNumber)

void testRunStarted (String name, int numTests, int attemptNumber, long startTime)

void testStarted (TestDescription test, long startTime)

公共建設者

模塊監聽器

public ModuleListener (ITestInvocationListener listener)

構造函數。

參量
listener ITestInvocationListener

公開方法

hasLastAttemptFailed

public boolean hasLastAttemptFailed ()

返回偵聽器的上一次重試會話是否失敗。

退貨
boolean

logAssociation

public void logAssociation (String dataName, 
                LogFile logFile)

參量
dataName String

logFile LogFile

setCollectTestsOnly

4

設置是否僅收集測試。

參量
collectTestsOnly boolean

setMarkTestsSkipped

public void setMarkTestsSkipped (boolean skip)

是否標記所有已跳過的測試用例。

參量
skip boolean

testAssumptionFailure

public void testAssumptionFailure (TestDescription test, 
                String trace)

參量
test TestDescription

trace String

testAssumptionFailure

public void testAssumptionFailure (TestDescription test, 
                FailureDescription failure)

參量
test TestDescription

failure FailureDescription

testEnded

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

參量
test TestDescription

endTime long

testMetrics

testEnded

public void testEnded (TestDescription test, 
                 testMetrics)

參量
test TestDescription

testMetrics

測試失敗

public void testFailed (TestDescription test, 
                FailureDescription failure)

參量
test TestDescription

failure FailureDescription

測試失敗

public void testFailed (TestDescription test, 
                String trace)

參量
test TestDescription

trace String

testIgnored

public void testIgnored (TestDescription test)

參量
test TestDescription

測試日誌

public void testLog (String dataName, 
                LogDataType dataType, 
                InputStreamSource dataStream)

參量
dataName String

dataType LogDataType

dataStream InputStreamSource

testLogSaved

public void testLogSaved (String dataName, 
                LogDataType dataType, 
                InputStreamSource dataStream, 
                LogFile logFile)

參量
dataName String

dataType LogDataType

dataStream InputStreamSource

logFile LogFile

testRunEnded

public void testRunEnded (long elapsedTime, 
                 runMetrics)

參量
elapsedTime long

runMetrics

testRunFailed

public void testRunFailed (FailureDescription failure)

參量
failure FailureDescription

testRunFailed

public void testRunFailed (String errorMessage)

參量
errorMessage String

testRunStarted

534

參量
name String

numTests int

attemptNumber int

testRunStarted

public void testRunStarted (String name, 
                int numTests, 
                int attemptNumber, 
                long startTime)

參量
name String

numTests int

attemptNumber int

startTime long

testStarted

public void testStarted (TestDescription test, 
                long startTime)

參量
test TestDescription

startTime long