We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 239e456 commit 04ea861Copy full SHA for 04ea861
.gitignore
@@ -1,4 +1,5 @@
1
.c9/
2
+.idea/
3
node_modules/
4
test/subdir/
5
test/*.xml
index.js
@@ -14,7 +14,7 @@ var mocha6plus;
14
15
try {
16
var json = JSON.parse(
17
- fs.readFileSync("./node_modules/mocha/package.json", "utf8")
+ fs.readFileSync(path.dirname(require.resolve('mocha')) + "/package.json", "utf8")
18
);
19
var version = json.version;
20
if (version >= "6") {
@@ -24,6 +24,7 @@ try {
24
mocha6plus = false;
25
}
26
} catch (e) {
27
+ // eslint-disable-next-line no-console
28
console.warn("Couldn't determine Mocha version");
29
30
module.exports = MochaJUnitReporter;
0 commit comments