Skip to content

Commit

Permalink
prepare CHANGELOG for v5.0.2 [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
boneskull committed Mar 6, 2018
1 parent 0542c40 commit 6a796cb
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,40 @@
# 5.0.2 / 2018-03-05

This release fixes a class of tests which report as *false positives*. **Certain tests will now break**, though they would have previously been reported as passing. Details below. Sorry for the inconvenience!

## :bug: Fixes

- [#3226]: Do not swallow errors that are thrown asynchronously from passing tests ([@boneskull]). Example:

```js
it('should actually fail, sorry!', function (done) {
// passing assertion
assert(true === true);

// test complete & is marked as passing
done();

// ...but something evil lurks within
setTimeout(() => {
throw new Error('chaos!');
}, 100);
});
```

Previously to this version, Mocha would have *silently swallowed* the `chaos!` exception, and you wouldn't know. Well, *now you know*. Mocha cannot recover from this gracefully, so it will exit with a nonzero code.

**Maintainers of external reporters**: *If* a test of this class is encountered, the `Runner` instance will emit the `end` event *twice*; you *may* need to change your reporter to use `runner.once('end')` intead of `runner.on('end')`.
- [#3093]: Fix stack trace reformatting problem ([@outsideris])

## :nut_and_bolt Other

- [#3248]: Update `browser-stdout` to v1.3.1 ([@honzajavorek])

[#3248]: https://github.com/mochajs/mocha/issues/3248
[#3226]: https://github.com/mochajs/mocha/issues/3226
[#3093]: https://github.com/mochajs/mocha/issues/3093
[@honzajavorek]: https://github.com/honzajavorek

# 5.0.1 / 2018-02-07

...your garden-variety patch release.
Expand Down

0 comments on commit 6a796cb

Please sign in to comment.