You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Checked next-gen ES issues and syntax problems by using the same environment and/or transpiler configuration without Mocha to ensure it isn't just a feature that actually isn't supported in the environment in question or a bug in your code.
'Smoke tested' the code to be tested by running it outside the real test suite to get a better sense of whether the problem is in the code under test, your usage of Mocha, or Mocha itself
Ensured that there is no discrepancy between the locally and globally installed versions of Mocha. You can find them with: node node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend that you not install Mocha globally.
Description
Hi,
Since Mocha 9.1.0, when i launch my tests, i have the error message : Error: No test files found.
Adding "node-option": [], in my .mocharc.json configuration file seems to solve the problem.
It seems that Mocha does not consider the path given in "recursive": ["./tests/**/*.js"] without this option.
I don't know if it is the expected behaviour from #4691.
Steps to Reproduce
user@host ~$ git clone https://github.com/cyrilverloop/mocha-node-option.gituser@host ~$ cd mocha-node-optionuser@host mocha-node-option$ npm test
remove the option "node-option": [], in the .mocharc.json configuration file at the root of the project;
run the test to see the error message.
The text was updated successfully, but these errors were encountered:
@juergba changing "recursive" to "spec" was the answer i was looking for. Thanks !
I do not know why it worked before 9.1.0 nor why adding "node-option": [] makes it work now, but it does not matter to me.
I see that the "spec" default option is missing in .mocharc.json and .mocharc.jsonc. Should it be added ?
Prerequisites
faq
labelnode node_modules/.bin/mocha --version
(Local) andmocha --version
(Global). We recommend that you not install Mocha globally.Description
Hi,
Since Mocha 9.1.0, when i launch my tests, i have the error message :
Error: No test files found
.Adding
"node-option": [],
in my.mocharc.json
configuration file seems to solve the problem.It seems that Mocha does not consider the path given in
"recursive": ["./tests/**/*.js"]
without this option.I don't know if it is the expected behaviour from #4691.
Steps to Reproduce
"node-option": [],
in the.mocharc.json
configuration file at the root of the project;The text was updated successfully, but these errors were encountered: