I am planning to convert my testcafe console output to txt/html file with custom file name, I am using below line of script, but output file is not generating and no errors. I have installed the required report templates. Please guide me .
$ testcafe chrome tests/core/sample.test.js --reporter html:/file.html $ testcafe chrome tests/core/sample.test.js --reporter list:/test.txt
Thanks Ramesh D
Isn't this just easier?
I mean you can use reporters, you can build your own reporter and spend hours on that, or if you really just need a file out of console output, this should be enough.
I have a habit of using config files rather than command line options, so I'll show it on config files:
.testcaferc.json
First, of course, you need to install the appropriate npm package:
If you insist on a command-line option, this testcafe docs should guide you. I believe this would be the right command: