common mistake labelnode node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend avoiding the use of globally installed Mocha.
Mocha doesn't run all tests, just one
See the attached screenshots. Neither mocha test/*/.spec.js nor mocha --recursive work for me
Expected behavior: [What you expect to happen]
all tests in the directory should be executed
Actual behavior: [What actually happens]
Only one test is ran
Reproduces how often: [What percentage of the time does it reproduce?]
100%
mocha version 4.0.1
I'm getting this error on both OSX and Linux, regardless of globstar settings
I'm wondering if there is a bug. I'm getting this error on both OSX and Linux:



I don't understand which test file(s) aren't executed which are supposed to be. from that first screenshot, it looks like they all might be... but I can't really tell you more without more info about the repo.
you could try removing mocha.opts and see what happens
could it be an .only call?
Same here.
I made simple example: https://github.com/wertlex/mocha-recursive-issue
Issue is in npm run test-wildcard-recursive. Expected mocha will run tests from both test/admin and test/admin/superadmin, but only first one run.
Looks like mocha ./test/**/*.js --recursive not works as expected.
Found. This problem explained here: https://github.com/mochajs/mocha/issues/3136
@javahaxxor you just need quotes
@boneskull this issue can be closed
@wertlex I have quotes ..
@javahaxxor Can you show your example which has the problem like @wertlex
@javahaxxor grep for .only in your tests
Most helpful comment
could it be an
.onlycall?