We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
extends
1 parent 72273cb commit e76a0dfCopy full SHA for e76a0df
lib/cli/config.js
@@ -11,6 +11,7 @@ const fs = require('fs');
11
const path = require('path');
12
const debug = require('debug')('mocha:cli:config');
13
const findUp = require('find-up');
14
+const yargs = require('yargs/yargs');
15
const {createUnparsableFileError} = require('../errors');
16
const utils = require('../utils');
17
@@ -76,6 +77,10 @@ exports.loadConfig = filepath => {
76
77
} else {
78
config = parsers.json(filepath);
79
}
80
+
81
+ config = yargs(undefined, path.dirname(filepath))
82
+ .parserConfiguration(require('./options').YARGS_PARSER_CONFIG)
83
+ .config(config);
84
} catch (err) {
85
throw createUnparsableFileError(
86
`Unable to read/parse ${filepath}: ${err}`,
0 commit comments