visionmedia/mocha — pull request #1324 by ben-bradley (2014-08-25 16:34:07+00:00)
Title: added empty object to errorJSON() call to catch when no error is present

When using the json reporter (`-R json`), the `errorJSON()` function quietly dies if there is no `test.err` property. Feeding it an empty object allows it to succeed.

This also addresses #1314.