1
0
mirror of https://github.com/simple-icons/simple-icons.git synced 2024-11-26 01:00:27 +02:00
simple-icons/tests/min-reporter.cjs

23 lines
509 B
JavaScript
Raw Normal View History

2024-06-06 14:40:35 +02:00
/**
* @file Custom mocha reporter.
*
* Serves to clear the console after the test run is finished.
* See {@link https://github.com/mochajs/mocha/issues/2312}
*/
2024-03-24 19:38:18 +02:00
const {reporters, Runner} = require('mocha');
2024-03-24 19:38:18 +02:00
const {EVENT_RUN_END} = Runner.constants;
class EvenMoreMin extends reporters.Base {
2024-06-06 14:40:35 +02:00
/**
* @param {import('mocha').Runner} runner Mocha test runner
*/
constructor(runner) {
super(runner);
runner.once(EVENT_RUN_END, () => this.epilogue());
}
}
module.exports = EvenMoreMin;