mocha 8.3.2 → 8.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,21 @@
1
+ # 8.4.0 / 2021-05-07
2
+
3
+ ## :tada: Enhancements
4
+
5
+ - [#4502](https://github.com/mochajs/mocha/issues/4502): CLI file parsing errors now have error codes ([**@evaline-ju**](https://github.com/evaline-ju))
6
+
7
+ ## :bug: Fixes
8
+
9
+ - [#4614](https://github.com/mochajs/mocha/issues/4614): Watch: fix crash when reloading files ([**@outsideris**](https://github.com/outsideris))
10
+
11
+ ## :book: Documentation
12
+
13
+ - [#4630](https://github.com/mochajs/mocha/issues/4630): Add `options.require` to Mocha constructor for `root hook` plugins on parallel runs ([**@juergba**](https://github.com/juergba))
14
+ - [#4617](https://github.com/mochajs/mocha/issues/4617): Dynamically generating tests with `top-level await` and ESM test files ([**@juergba**](https://github.com/juergba))
15
+ - [#4608](https://github.com/mochajs/mocha/issues/4608): Update default file extensions ([**@outsideris**](https://github.com/outsideris))
16
+
17
+ Also thanks to [**@outsideris**](https://github.com/outsideris) for various improvements on our GH actions workflows.
18
+
1
19
  # 8.3.2 / 2021-03-12
2
20
 
3
21
  ## :bug: Fixes
package/README.md CHANGED
@@ -9,8 +9,8 @@
9
9
  <a href="https://coveralls.io/github/mochajs/mocha"><img src="https://coveralls.io/repos/github/mochajs/mocha/badge.svg" alt="Coverage Status"></a>
10
10
  <a href="https://app.fossa.io/projects/git%2Bhttps%3A%2F%2Fgithub.com%2Fmochajs%2Fmocha?ref=badge_shield"><img src="https://app.fossa.io/api/projects/git%2Bhttps%3A%2F%2Fgithub.com%2Fmochajs%2Fmocha.svg?type=shield" alt="FOSSA Status"></a>
11
11
  <a href="https://gitter.im/mochajs/mocha?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge"><img src="https://badges.gitter.im/Join%20Chat.svg" alt="Gitter"></a>
12
- <a href="https://github.com/mochajs/mocha#backers"><img src="https://opencollective.com/mochajs/backers/badge.svg" alt="OpenCollective"></a>
13
- <a href="https://github.com/mochajs/mocha#sponsors"><img src="https://opencollective.com/mochajs/sponsors/badge.svg" alt="OpenCollective"></a>
12
+ <a href="https://github.com/mochajs/mocha#sponsors"><img src="https://opencollective.com/mochajs/tiers/sponsors/badge.svg" alt="OpenCollective"></a>
13
+ <a href="https://github.com/mochajs/mocha#backers"><img src="https://opencollective.com/mochajs/tiers/backers/badge.svg" alt="OpenCollective"></a>
14
14
  </p>
15
15
 
16
16
  <p align="center">
@@ -27,74 +27,28 @@
27
27
  - [Code of Conduct](https://github.com/mochajs/mocha/blob/master/.github/CODE_OF_CONDUCT.md)
28
28
  - [Contributing](https://github.com/mochajs/mocha/blob/master/.github/CONTRIBUTING.md)
29
29
  - [Gitter Chatroom](https://gitter.im/mochajs/mocha) (ask questions here!)
30
- - [Google Group](https://groups.google.com/group/mochajs)
31
30
  - [Issue Tracker](https://github.com/mochajs/mocha/issues)
32
31
 
33
32
  ## Backers
34
33
 
35
- [Become a backer](https://opencollective.com/mochajs#backer) and show your support to our open source project.
36
-
37
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/0/avatar)](https://opencollective.com/mochajs/backer/0/website)
38
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/1/avatar)](https://opencollective.com/mochajs/backer/1/website)
39
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/2/avatar)](https://opencollective.com/mochajs/backer/2/website)
40
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/3/avatar)](https://opencollective.com/mochajs/backer/3/website)
41
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/4/avatar)](https://opencollective.com/mochajs/backer/4/website)
42
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/5/avatar)](https://opencollective.com/mochajs/backer/5/website)
43
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/6/avatar)](https://opencollective.com/mochajs/backer/6/website)
44
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/7/avatar)](https://opencollective.com/mochajs/backer/7/website)
45
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/8/avatar)](https://opencollective.com/mochajs/backer/8/website)
46
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/9/avatar)](https://opencollective.com/mochajs/backer/9/website)
47
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/10/avatar)](https://opencollective.com/mochajs/backer/10/website)
48
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/11/avatar)](https://opencollective.com/mochajs/backer/11/website)
49
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/12/avatar)](https://opencollective.com/mochajs/backer/12/website)
50
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/13/avatar)](https://opencollective.com/mochajs/backer/13/website)
51
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/14/avatar)](https://opencollective.com/mochajs/backer/14/website)
52
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/15/avatar)](https://opencollective.com/mochajs/backer/15/website)
53
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/16/avatar)](https://opencollective.com/mochajs/backer/16/website)
54
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/17/avatar)](https://opencollective.com/mochajs/backer/17/website)
55
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/18/avatar)](https://opencollective.com/mochajs/backer/18/website)
56
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/19/avatar)](https://opencollective.com/mochajs/backer/19/website)
57
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/20/avatar)](https://opencollective.com/mochajs/backer/20/website)
58
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/21/avatar)](https://opencollective.com/mochajs/backer/21/website)
59
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/22/avatar)](https://opencollective.com/mochajs/backer/22/website)
60
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/23/avatar)](https://opencollective.com/mochajs/backer/23/website)
61
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/24/avatar)](https://opencollective.com/mochajs/backer/24/website)
62
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/25/avatar)](https://opencollective.com/mochajs/backer/25/website)
63
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/26/avatar)](https://opencollective.com/mochajs/backer/26/website)
64
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/27/avatar)](https://opencollective.com/mochajs/backer/27/website)
65
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/28/avatar)](https://opencollective.com/mochajs/backer/28/website)
66
- [![MochaJS Backer](https://opencollective.com/mochajs/backer/29/avatar)](https://opencollective.com/mochajs/backer/29/website)
34
+ [Become a backer](https://opencollective.com/mochajs) and show your support to our open source project on [our site](https://mochajs.org/#backers).
35
+
36
+ <a href="https://opencollective.com/mochajs"><img src="https://opencollective.com/mochajs/tiers/backers.svg?limit=30&button=false&avatarHeight=46&width=750"></a>
67
37
 
68
38
  ## Sponsors
69
39
 
70
- Does your company use Mocha? Ask your manager or marketing team if your company would be interested in supporting our project. Support will allow the maintainers to dedicate more time for maintenance and new features for everyone. Also, your company's logo will show [on GitHub](https://github.com/mochajs/mocha#readme) and on [our site](https://mochajs.org) - who doesn't want a little extra exposure? [Here's the info](https://opencollective.com/mochajs#sponsor).
71
-
72
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/0/avatar)](https://opencollective.com/mochajs/sponsor/0/website)
73
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/1/avatar)](https://opencollective.com/mochajs/sponsor/1/website)
74
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/2/avatar)](https://opencollective.com/mochajs/sponsor/2/website)
75
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/3/avatar)](https://opencollective.com/mochajs/sponsor/3/website)
76
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/4/avatar)](https://opencollective.com/mochajs/sponsor/4/website)
77
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/5/avatar)](https://opencollective.com/mochajs/sponsor/5/website)
78
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/6/avatar)](https://opencollective.com/mochajs/sponsor/6/website)
79
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/7/avatar)](https://opencollective.com/mochajs/sponsor/7/website)
80
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/8/avatar)](https://opencollective.com/mochajs/sponsor/8/website)
81
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/9/avatar)](https://opencollective.com/mochajs/sponsor/9/website)
82
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/10/avatar)](https://opencollective.com/mochajs/sponsor/10/website)
83
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/11/avatar)](https://opencollective.com/mochajs/sponsor/11/website)
84
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/12/avatar)](https://opencollective.com/mochajs/sponsor/12/website)
85
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/13/avatar)](https://opencollective.com/mochajs/sponsor/13/website)
86
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/14/avatar)](https://opencollective.com/mochajs/sponsor/14/website)
87
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/15/avatar)](https://opencollective.com/mochajs/sponsor/15/website)
88
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/16/avatar)](https://opencollective.com/mochajs/sponsor/16/website)
89
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/17/avatar)](https://opencollective.com/mochajs/sponsor/17/website)
90
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/18/avatar)](https://opencollective.com/mochajs/sponsor/18/website)
91
- [![MochaJS Sponsor](https://opencollective.com/mochajs/sponsor/19/avatar)](https://opencollective.com/mochajs/sponsor/19/website)
40
+ Does your company use Mocha? Ask your manager or marketing team if your company would be interested in supporting our project. Support will allow the maintainers to dedicate more time for maintenance and new features for everyone. Also, your company's logo will show [on GitHub](https://github.com/mochajs/mocha#readme) and on [our site](https://mochajs.org#sponsors) - who doesn't want a little extra exposure? [Here's the info](https://opencollective.com/mochajs).
41
+
42
+ [![MochaJS Sponsor](https://opencollective.com/mochajs/tiers/sponsors/0/avatar)](https://opencollective.com/mochajs/tiers/sponsors/0/website)
43
+ [![MochaJS Sponsor](https://opencollective.com/mochajs/tiers/sponsors/1/avatar)](https://opencollective.com/mochajs/tiers/sponsors/1/website)
44
+ [![MochaJS Sponsor](https://opencollective.com/mochajs/tiers/sponsors/2/avatar)](https://opencollective.com/mochajs/tiers/sponsors/2/website)
45
+ [![MochaJS Sponsor](https://opencollective.com/mochajs/tiers/sponsors/3/avatar)](https://opencollective.com/mochajs/tiers/sponsors/3/website)
92
46
 
93
47
  ## Development
94
48
 
95
49
  You might want to know that:
96
50
 
97
- - Mocha is the _most-depended-upon_ module on npm (source: [libraries.io](https://libraries.io/search?order=desc&platforms=NPM&sort=dependents_count)), and
51
+ - Mocha is one of the _most-depended-upon_ modules on npm (source: [libraries.io](https://libraries.io/search?order=desc&platforms=NPM&sort=dependents_count)), and
98
52
  - Mocha is an _independent_ open-source project, maintained exclusively by volunteers.
99
53
 
100
54
  You might want to help:
package/lib/cli/config.js CHANGED
@@ -11,6 +11,7 @@ const fs = require('fs');
11
11
  const path = require('path');
12
12
  const debug = require('debug')('mocha:cli:config');
13
13
  const findUp = require('find-up');
14
+ const {createUnparsableFileError} = require('../errors');
14
15
  const utils = require('../utils');
15
16
 
16
17
  /**
@@ -81,7 +82,10 @@ exports.loadConfig = filepath => {
81
82
  config = parsers.json(filepath);
82
83
  }
83
84
  } catch (err) {
84
- throw new Error(`failed to parse config "${filepath}": ${err}`);
85
+ throw createUnparsableFileError(
86
+ `Unable to read/parse ${filepath}: ${err}`,
87
+ filepath
88
+ );
85
89
  }
86
90
  return config;
87
91
  };
@@ -18,6 +18,7 @@ const {loadConfig, findConfig} = require('./config');
18
18
  const findUp = require('find-up');
19
19
  const debug = require('debug')('mocha:cli:options');
20
20
  const {isNodeFlag} = require('./node-flags');
21
+ const {createUnparsableFileError} = require('../errors');
21
22
 
22
23
  /**
23
24
  * The `yargs-parser` namespace
@@ -190,7 +191,10 @@ const loadPkgRc = (args = {}) => {
190
191
  }
191
192
  } catch (err) {
192
193
  if (args.package) {
193
- throw new Error(`Unable to read/parse ${filepath}: ${err}`);
194
+ throw createUnparsableFileError(
195
+ `Unable to read/parse ${filepath}: ${err}`,
196
+ filepath
197
+ );
194
198
  }
195
199
  debug('failed to read default package.json at %s; ignoring', filepath);
196
200
  }
@@ -261,17 +261,21 @@ const createRerunner = (mocha, watcher, {beforeRun} = {}) => {
261
261
  let rerunScheduled = false;
262
262
 
263
263
  const run = () => {
264
- mocha = beforeRun ? beforeRun({mocha, watcher}) || mocha : mocha;
265
- runner = mocha.run(() => {
266
- debug('finished watch run');
267
- runner = null;
268
- blastCache(watcher);
269
- if (rerunScheduled) {
270
- rerun();
271
- } else {
272
- console.error(`${logSymbols.info} [mocha] waiting for changes...`);
273
- }
274
- });
264
+ try {
265
+ mocha = beforeRun ? beforeRun({mocha, watcher}) || mocha : mocha;
266
+ runner = mocha.run(() => {
267
+ debug('finished watch run');
268
+ runner = null;
269
+ blastCache(watcher);
270
+ if (rerunScheduled) {
271
+ rerun();
272
+ } else {
273
+ console.error(`${logSymbols.info} [mocha] waiting for changes...`);
274
+ }
275
+ });
276
+ } catch (e) {
277
+ console.error(e.stack);
278
+ }
275
279
  };
276
280
 
277
281
  const scheduleRun = () => {
package/lib/errors.js CHANGED
@@ -163,7 +163,14 @@ var constants = {
163
163
  * @constant
164
164
  * @default
165
165
  */
166
- TIMEOUT: 'ERR_MOCHA_TIMEOUT'
166
+ TIMEOUT: 'ERR_MOCHA_TIMEOUT',
167
+
168
+ /**
169
+ * Input file is not able to be parsed
170
+ * @constant
171
+ * @default
172
+ */
173
+ UNPARSABLE_FILE: 'ERR_MOCHA_UNPARSABLE_FILE'
167
174
  };
168
175
 
169
176
  /**
@@ -495,6 +502,20 @@ function createTimeoutError(msg, timeout, file) {
495
502
  return err;
496
503
  }
497
504
 
505
+ /**
506
+ * Creates an error object to be thrown when file is unparsable
507
+ * @public
508
+ * @static
509
+ * @param {string} message - Error message to be displayed.
510
+ * @param {string} filename - File name
511
+ * @returns {Error} Error with code {@link constants.UNPARSABLE_FILE}
512
+ */
513
+ function createUnparsableFileError(message, filename) {
514
+ var err = new Error(message);
515
+ err.code = constants.UNPARSABLE_FILE;
516
+ return err;
517
+ }
518
+
498
519
  /**
499
520
  * Returns `true` if an error came out of Mocha.
500
521
  * _Can suffer from false negatives, but not false positives._
@@ -525,6 +546,7 @@ module.exports = {
525
546
  createMultipleDoneError,
526
547
  createNoFilesMatchPatternError,
527
548
  createTimeoutError,
549
+ createUnparsableFileError,
528
550
  createUnsupportedError,
529
551
  deprecate,
530
552
  isMochaError,
@@ -105,13 +105,6 @@ module.exports = function bddInterface(suite) {
105
105
  context.xit = context.xspecify = context.it.skip = function(title) {
106
106
  return context.it(title);
107
107
  };
108
-
109
- /**
110
- * Number of attempts to retry.
111
- */
112
- context.it.retries = function(n) {
113
- context.retries(n);
114
- };
115
108
  });
116
109
  };
117
110
 
@@ -187,15 +187,6 @@ module.exports = function(suites, context, mocha) {
187
187
  */
188
188
  skip: function(title) {
189
189
  context.test(title);
190
- },
191
-
192
- /**
193
- * Number of retry attempts
194
- *
195
- * @param {number} n
196
- */
197
- retries: function(n) {
198
- context.retries(n);
199
190
  }
200
191
  }
201
192
  };
@@ -92,7 +92,6 @@ module.exports = function qUnitInterface(suite) {
92
92
  };
93
93
 
94
94
  context.test.skip = common.test.skip;
95
- context.test.retries = common.test.retries;
96
95
  });
97
96
  };
98
97
 
@@ -99,7 +99,6 @@ module.exports = function(suite) {
99
99
  };
100
100
 
101
101
  context.test.skip = common.test.skip;
102
- context.test.retries = common.test.retries;
103
102
  });
104
103
  };
105
104
 
package/lib/mocha.js CHANGED
@@ -180,10 +180,10 @@ exports.run = function(...args) {
180
180
  * @param {number} [options.slow] - Slow threshold value.
181
181
  * @param {number|string} [options.timeout] - Timeout threshold value.
182
182
  * @param {string} [options.ui] - Interface name.
183
- * @param {boolean} [options.parallel] - Run jobs in parallel
184
- * @param {number} [options.jobs] - Max number of worker processes for parallel runs
185
- * @param {MochaRootHookObject} [options.rootHooks] - Hooks to bootstrap the root
186
- * suite with
183
+ * @param {boolean} [options.parallel] - Run jobs in parallel.
184
+ * @param {number} [options.jobs] - Max number of worker processes for parallel runs.
185
+ * @param {MochaRootHookObject} [options.rootHooks] - Hooks to bootstrap the root suite with.
186
+ * @param {string[]} [options.require] - Pathname of `rootHooks` plugin for parallel runs.
187
187
  * @param {boolean} [options.isWorker] - Should be `true` if `Mocha` process is running in a worker process.
188
188
  */
189
189
  function Mocha(options = {}) {
package/mocha.js CHANGED
@@ -19987,7 +19987,14 @@
19987
19987
  * @constant
19988
19988
  * @default
19989
19989
  */
19990
- TIMEOUT: 'ERR_MOCHA_TIMEOUT'
19990
+ TIMEOUT: 'ERR_MOCHA_TIMEOUT',
19991
+
19992
+ /**
19993
+ * Input file is not able to be parsed
19994
+ * @constant
19995
+ * @default
19996
+ */
19997
+ UNPARSABLE_FILE: 'ERR_MOCHA_UNPARSABLE_FILE'
19991
19998
  };
19992
19999
  /**
19993
20000
  * A set containing all string values of all Mocha error constants, for use by {@link isMochaError}.
@@ -20331,6 +20338,21 @@
20331
20338
  err.file = file;
20332
20339
  return err;
20333
20340
  }
20341
+ /**
20342
+ * Creates an error object to be thrown when file is unparsable
20343
+ * @public
20344
+ * @static
20345
+ * @param {string} message - Error message to be displayed.
20346
+ * @param {string} filename - File name
20347
+ * @returns {Error} Error with code {@link constants.UNPARSABLE_FILE}
20348
+ */
20349
+
20350
+
20351
+ function createUnparsableFileError(message, filename) {
20352
+ var err = new Error(message);
20353
+ err.code = constants.UNPARSABLE_FILE;
20354
+ return err;
20355
+ }
20334
20356
  /**
20335
20357
  * Returns `true` if an error came out of Mocha.
20336
20358
  * _Can suffer from false negatives, but not false positives._
@@ -20364,6 +20386,7 @@
20364
20386
  createMultipleDoneError: createMultipleDoneError,
20365
20387
  createNoFilesMatchPatternError: createNoFilesMatchPatternError,
20366
20388
  createTimeoutError: createTimeoutError,
20389
+ createUnparsableFileError: createUnparsableFileError,
20367
20390
  createUnsupportedError: createUnsupportedError,
20368
20391
  deprecate: deprecate$1,
20369
20392
  isMochaError: isMochaError,
@@ -27190,7 +27213,7 @@
27190
27213
  });
27191
27214
 
27192
27215
  var name = "mocha";
27193
- var version$2 = "8.3.2";
27216
+ var version$2 = "8.4.0";
27194
27217
  var homepage = "https://mochajs.org/";
27195
27218
  var notifyLogo = "https://ibin.co/4QuRuGjXvl36.png";
27196
27219
  var _package = {
@@ -27784,15 +27807,6 @@
27784
27807
  */
27785
27808
  skip: function skip(title) {
27786
27809
  context.test(title);
27787
- },
27788
-
27789
- /**
27790
- * Number of retry attempts
27791
- *
27792
- * @param {number} n
27793
- */
27794
- retries: function retries(n) {
27795
- context.retries(n);
27796
27810
  }
27797
27811
  }
27798
27812
  };
@@ -27898,14 +27912,6 @@
27898
27912
  context.xit = context.xspecify = context.it.skip = function (title) {
27899
27913
  return context.it(title);
27900
27914
  };
27901
- /**
27902
- * Number of attempts to retry.
27903
- */
27904
-
27905
-
27906
- context.it.retries = function (n) {
27907
- context.retries(n);
27908
- };
27909
27915
  });
27910
27916
  };
27911
27917
 
@@ -28012,7 +28018,6 @@
28012
28018
  };
28013
28019
 
28014
28020
  context.test.skip = common.test.skip;
28015
- context.test.retries = common.test.retries;
28016
28021
  });
28017
28022
  };
28018
28023
 
@@ -28109,7 +28114,6 @@
28109
28114
  };
28110
28115
 
28111
28116
  context.test.skip = common.test.skip;
28112
- context.test.retries = common.test.retries;
28113
28117
  });
28114
28118
  };
28115
28119
 
@@ -28503,10 +28507,10 @@
28503
28507
  * @param {number} [options.slow] - Slow threshold value.
28504
28508
  * @param {number|string} [options.timeout] - Timeout threshold value.
28505
28509
  * @param {string} [options.ui] - Interface name.
28506
- * @param {boolean} [options.parallel] - Run jobs in parallel
28507
- * @param {number} [options.jobs] - Max number of worker processes for parallel runs
28508
- * @param {MochaRootHookObject} [options.rootHooks] - Hooks to bootstrap the root
28509
- * suite with
28510
+ * @param {boolean} [options.parallel] - Run jobs in parallel.
28511
+ * @param {number} [options.jobs] - Max number of worker processes for parallel runs.
28512
+ * @param {MochaRootHookObject} [options.rootHooks] - Hooks to bootstrap the root suite with.
28513
+ * @param {string[]} [options.require] - Pathname of `rootHooks` plugin for parallel runs.
28510
28514
  * @param {boolean} [options.isWorker] - Should be `true` if `Mocha` process is running in a worker process.
28511
28515
  */
28512
28516