Reputation: 202138
We have a project in Git containing several modules with the following structures:
project
|- module1
|- package.json
(...)
|- module2
|- package.json
(...)
Each package.json
file has a test
entry to execute tests of the module. So we can execute tests for a particular module like this (in the corresponding sub folder):
$ npm run test
Is it possible to configure such a project in CircleCI?
Thanks very much for your help!
Upvotes: 1
Views: 320
Reputation: 4017
Yes you can, in a very similar fashion to how you would do it locally. In your circle.yml
file test section, you would have a line for each module. Something like:
test:
override:
- cd module1; npm run test
- cd module2; npm run test
More information on how to use circle.yml
can be found here.
-Ricardo
Developer Evangelist, CircleCI
Upvotes: 1