Skip to content

Commit

Permalink
spawn child-process for 'esm'
Browse files Browse the repository at this point in the history
  • Loading branch information
juergba committed Aug 10, 2019
1 parent 8e6e747 commit de3adfa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion bin/mocha
Expand Up @@ -117,7 +117,10 @@ if (nodeArgs.gc) {
delete nodeArgs.gc;
}

if (Object.keys(nodeArgs).length) {
if (
Object.keys(nodeArgs).length ||
(mochaArgs.require && mochaArgs.require.includes('esm'))
) {
const {spawn} = require('child_process');
const mochaPath = require.resolve('../lib/cli/cli.js');

Expand Down

0 comments on commit de3adfa

Please sign in to comment.