faq labelnode node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend that you _not_ install Mocha globally.
Running tests in the terminal (bash) with the nyan and progress reporters are broken, the output is a mess.
Run npx mocha -R nyan test.js or npx mocha -R progress test.js with the following file:
const assert = require('assert');
describe('Bug test', () => {
for(let i = 0; i < 200; i++) {
it('Should do something', () => assert(true));
}
});
Expected behavior: [What you expect to happen]
The nyan cat or the progress bar shouldn't exceed terminal width.
Actual behavior: [What actually happens]
It breakes awfully, by exceeding the terminal width and generating unexpected line breaks.
Reproduces how often: [What percentage of the time does it reproduce?]
100%
mocha --version and node node_modules/.bin/mocha --version: 8.1.0node --version: v12.14.1
It works properly in 8.0.1
I'm seeing similar line-break issues with the 'dot' reporter, also fine in 8.0.1.
8.0.1

8.1.0

yikes, ty.
I see the issue, will publish a fix soon
Ref: #4394
fixed in v8.1.1
Most helpful comment
fixed in v8.1.1