Closed kweij closed 4 years ago
Thank you for your inquiry. This issue looks like a question that would be best asked on StackOverflow - an amazing platform for users to ask and answer questions.
You can use the following approaches to redirect the reporter's output to a file:
testCafe
.createRunner()
.src('path/to/test/file.js')
.browsers('chrome')
.reporter('xunit', 'report.xml')
.run();
testCafe
.createRunner()
.src('path/to/test/file.js')
.browsers('chrome')
.reporter({ name: 'xunit', output: 'report.xml' })
.run();
Thanks you so much for the quick response. And indeed, I should've posted this on StackOverflow.
Documentation state the following usage:
But how can I specify a filename to write out the results? Setting the reporter like this only formats the console.logged output, but I want it in a file.
Thanks in advance