testdouble / teenytest

A very simple, zero-config test runner for Node.js
MIT License
96 stars 14 forks source link

Print summary at the bottom of a test run #33

Closed searls closed 6 years ago

searls commented 6 years ago

Now that I have a few teenytest suites with hundreds of tests, digging through the output to find a single failure in a test run is too much of a pain. At @schoonology's advice, I decided to just tack on a bunch of one-line comments at the end of the TAP input to summarize the test run (totals as well as reiterating failures.

It's a bit of a shame that the error-printing logic is separate for the failure summaries, but that was hard to avoid in this case and I didn't want unwinding that to become a showstopper to shipping this.