Skip to content

Commit

Permalink
pass mocha instance to helper function
Browse files Browse the repository at this point in the history
  • Loading branch information
khoaHyh committed Jun 18, 2024
1 parent 118fa4c commit 5c076cd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/cli/run-helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ const singleRun = async (mocha, {exit}, fileCollectParams) => {
const fileCollectionObj = collectFiles(fileCollectParams);

if (fileCollectionObj.unmatchedFiles.length > 0) {
return handleUnmatchedFiles(fileCollectionObj.unmatchedFiles);
return handleUnmatchedFiles(mocha, fileCollectionObj.unmatchedFiles);
}

debug('single run with %d file(s)', fileCollectionObj.files.length);
Expand Down Expand Up @@ -176,7 +176,7 @@ const parallelRun = async (mocha, options, fileCollectParams) => {
const fileCollectionObj = collectFiles(fileCollectParams);

if (fileCollectionObj.unmatchedFiles.length > 0) {
return handleUnmatchedFiles(fileCollectionObj.unmatchedFiles);
return handleUnmatchedFiles(mocha, fileCollectionObj.unmatchedFiles);
}

debug(
Expand Down

0 comments on commit 5c076cd

Please sign in to comment.