nodeunit icon indicating copy to clipboard operation
nodeunit copied to clipboard

catch exceptions that occur when printing test failures

Open danbrakeley opened this issue 11 years ago • 0 comments

My specific case involved an object with circular references. When making a call to strictEqual(), I was getting:

TypeError: Converting circular structure to JSON

And then it would crash without running the rest of the tests or displaying the "FAILURES: 8/3136 assertions failed (3792ms)" line.

With this fix, I get a better display, a full stack trace, and the tests keep running.

danbrakeley avatar Aug 19 '14 16:08 danbrakeley