I have my tests grouped in folders, like this:
test/
├── unit/
├── integration/
└── acceptance/
In each of the above folders, there are a number of test files (e.g. test.js
)
I execute my different test suites with the following commands:
mocha test/unit/**/*.js
mocha test/integration/**/*.js
mocha test/acceptance/**/*.js
I recently decided to add a subfolder to test/unit
, to organise things a bit:
test/
└── unit/
├── subfolder/
│ └── new.test.js
├── foo.test.js
└── bar.test.js
But now mocha
is only executing the tests in new.test.js
.
I thought /**/*.js
meant that it would recursively look in all folders for .js
files, but that's not the behaviour I'm seeing. Is this a bug or a misunderstanding on my part?