Reporting
The TestingBot Cypress CLI contains an option to generate reports from your Cypress Runs, similar to other reporters such as mocha-awesome.
To generate a report, please specify the --reporter
flag:
Argument | Shorthand Argument | Accepted Values |
---|---|---|
--reporter |
-r |
You can choose to use the json reporter, or the junit reporter |
JUnit Reporter
The JUnit reporter is especially useful if you intend to run your Cypress tests in a CI such as Jenkins.
Here's an example how to generate a JUnit report:
Most CI systems will be able to parse the report.
The CI can then show a list of specs/tests that you ran on TestingBot, together with information such as:
- How long each spec took to run
- Whether the spec passed or not
- The full error message if a spec failed
By default, the reporter will output the report in a file called test-results.xml
, in the same directory where you run the CLI command from.
You can choose to change the location of this file with:
JSON Reporter
The JSON reporter will output all data to a JSON file, similar to a report generated with mochawesome-report-generator
Here's an example how to generate a JSON report:
By default, the reporter will output the report in a file called results.json
, in the same directory where you run the CLI command from.
You can choose to change the location of this file with: