Combining code coverage reports in javascript for coveralls
Asked Answered
V

1

6

I have node.js based projects that also include client side code. I have 2 separate unit test suites, 1 for front end and 1 for back end. I currently have mocha running using blanket for code coverage and piping the result into the coveralls module like so:

mocha --require blanket --reporter mocha-lcov-reporter server/test/unit | ./node_modules/.bin/coveralls

I essentially need to combine the output of these 2 test runs (server and client):

mocha --require blanket --reporter mocha-lcov-reporter server/test/unit

and

mocha --require blanket --reporter mocha-lcov-reporter client/test/unit

and pipe that into the coveralls module.

Is this possible? How would I do this?

Verbatim answered 9/2, 2014 at 12:4 Comment(0)
M
2

I used gulp and a coveralls plugin to accomplish this:

http://gulpjs.com/

https://www.npmjs.org/package/gulp-coveralls

Mayo answered 17/9, 2014 at 15:11 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.