You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+30Lines changed: 30 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -529,6 +529,36 @@ If you choose the CI-only reporting or even no reporting (CLI is always on) you
529
529
$ backstop openReport
530
530
```
531
531
532
+
### Reporting in custom format
533
+
534
+
To format tests output in a custom way you may provide a script that will transform data. Add below configuration to your test config.
535
+
536
+
```json
537
+
"customReports": {
538
+
"reports": [
539
+
{
540
+
"script": "customReports/customReport.js",
541
+
"name": "resultName.json"
542
+
}
543
+
],
544
+
"reportLocation": "backstop_data/custom_report"
545
+
}
546
+
```
547
+
548
+
Your script `customReport.js` should take `config, reporter, resultName` as parameters and return a `Promise` when result is processed.
549
+
To see example see `/test/configs/backstop_data/engine_scripts/customReports/xrayReport.js`. It can also incorporate additional information passed within scenarios like below:
0 commit comments