Last updated: Jul 12, 2017 11:59
Code Snippet - Selenium: Retrieve the test report URL, device id, and execution id
When using Selenium or Appium, it is possible to retrieve information from the driver that allows access to the Perfecto Reports. The driver capabilities provide information that is useful in retrieving the execution report for your test script.
Use the Selenium getCapabilities() method to retrieve the full capabilities associated with your automation driver and use the following capabilities to access the report related information:
|testGridReportUrl||Returns the URL to access the Reporting Library Grid for this execution|
|reportPdfUrl||Returns the URL to download a PDF formatted copy of the Execution Test Summary Report|
|reportKey||For users still using the legacy Perfecto report - the Perfecto Lab key used to access the legacy report.|
|executionId||The Perfecto Lab identifier for the current execution. May be used to identify the report in the Report Grid.|
|deviceName||The name of the device used in this test execution.|
The following snippet shows how to retrieve the URL of the Execution Test Report and the Execution identifier.