Using Rspec, I want to be able to both see the standard progress bar, and output to a file containing the generated spec sheet in documentation format, and also have an html file generated, without running the tests multiple times.
How do I assign multiple formats and file targets for those formats?
I figured out how to do this. You can add the following to your .rspec file (or wherever you want to throw in these options, really)
--format progress
--format documentation --color -o "documentation/file"
--format html -o "web/file"
You can add multiple formats, and it will do ALL of them. You can then set the target of those formats (so they aren't just interlaced in your standard output) with the "-o" command, followed by the name of the file to create.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With