GTestXmlResultParser
public
class
GTestXmlResultParser
extends Object
| java.lang.Object | |
| ↳ | com.android.tradefed.testtype.GTestXmlResultParser |
Parses the 'xml output mode' results of native tests using GTest that run from shell, and informs a ITestRunListener of the results.
Summary
Public constructors | |
|---|---|
GTestXmlResultParser(String testRunName, ITestInvocationListener listener)
Creates the GTestXmlResultParser for a single listener. |
|
GTestXmlResultParser(String testRunName, Collection<ITestInvocationListener> listeners)
Creates the GTestXmlResultParser. |
|
Public methods | |
|---|---|
Set<String>
|
getFailedTests()
Returns a list of tests that failed during the current test run. |
boolean
|
isTestRunIncomplete()
Whether the test run was incomplete or not. |
void
|
parseResult(File f, CollectingOutputReceiver output)
Parse the xml results |
Public constructors
GTestXmlResultParser
public GTestXmlResultParser (String testRunName,
ITestInvocationListener listener)Creates the GTestXmlResultParser for a single listener.
| Parameters | |
|---|---|
testRunName |
String: the test run name to provide to ITestInvocationListener.testRunStarted(String,int) |
listener |
ITestInvocationListener: informed of test results as the tests are executing |
GTestXmlResultParser
public GTestXmlResultParser (String testRunName,
Collection<ITestInvocationListener> listeners)Creates the GTestXmlResultParser.
| Parameters | |
|---|---|
testRunName |
String: the test run name to provide to ITestInvocationListener.testRunStarted(String,int) |
listeners |
Collection: informed of test results as the tests are executing |
Public methods
getFailedTests
public Set<String> getFailedTests ()
Returns a list of tests that failed during the current test run.
| Returns | |
|---|---|
Set<String> |
|
isTestRunIncomplete
public boolean isTestRunIncomplete ()
Whether the test run was incomplete or not.
| Returns | |
|---|---|
boolean |
true, if the test run was incomplete due to parsing issues or crashes. |
parseResult
public void parseResult (File f,
CollectingOutputReceiver output)Parse the xml results
| Parameters | |
|---|---|
f |
File: File containing the outputed xml |
output |
CollectingOutputReceiver: The output collected from the execution run to complete the logs if necessary |