☕️ Classic, reliable, trusted test framework for Node.js and the browser
Add to reporter mocha options
Denis Bardadym755f05410d8b
diff --git a/lib/mocha.js b/lib/mocha.jsindex 3bc9bd54..dabb4096 100644--- a/lib/mocha.js+++ b/lib/mocha.js@@ -356,8 +356,9 @@ Mocha.prototype.run = function(fn){if (this.files.length) this.loadFiles();var suite = this.suite;var options = this.options;+ options.files = this.files;var runner = new exports.Runner(suite);- var reporter = new this._reporter(runner);+ var reporter = new this._reporter(runner, options);runner.ignoreLeaks = false !== options.ignoreLeaks;runner.asyncOnly = options.asyncOnly;if (options.grep) runner.grep(options.grep, options.invert);