This command line interface is designed to extract XCTest and Espresso test execution results for a single test suite from the Perfect Reporting API via REST and convert the resulting JSON to Junit XML and write it to a file.
Either run at the command line:
com.perfectomobile.Exporter -c=https://example.app.perfectomobile.com -s=[SECURITY TOKEN OBTAINED FROM PERFECTO QUALITY LAB CLOUD] -e=[GUID REPRESENTING TEST SUITE EXECUTED IN THE PERFECTO QUALITY LAB] -x=./TestSuites.xml
Or create an Eclipse run configuration:
- c | perfectoCloudReportingServer
- Example: -c=https://example.app.perfectomobile.com
- s | perfectoSecurityToken
- Example: -s=[SECURITY TOKEN OBTAINED FROM PERFECTO QUALITY LAB CLOUD]
- x | xmlOutputFilePath
- Example: -x=./TestSuites.xml
- l | list [all executions in the past 24 hours]
- Example: -l
- e | testExecutionId
- Example: -e=[GUID REPRESENTING TEST SUITE EXECUTED IN THE PERFECTO QUALITY LAB]
- t | tag
- Example: -t=ExampleTestTag
- j | jsonOutputFilePath
- Example: -j=./TestSuites.json
- v | verbose
- Example: -v
To create an executable jar in Eclipse, select the File menu | Export. In the export wizard, choose Java > Runnable JAR file. Follow the wizard to select your launch configuration and file path.
See also Create runnable jar with Eclipse.
The core of the TestUnits XML class used to serialize the results was borrowed from Adam Gent.