Added code coverage and HighLevelProducer tests.#422
Added code coverage and HighLevelProducer tests.#422hyperlink merged 4 commits intoSOHU-Co:masterfrom
Conversation
test/test.client.js
Outdated
| zk = new FakeZookeeper(); | ||
|
|
||
| Client = proxyquire('../lib/Client', { | ||
| Client = proxyquire('../lib/client.js', { |
There was a problem hiding this comment.
should be able to omit the .js
There was a problem hiding this comment.
You are right @hyperlink - I amended the commit and verified the build is still successful on Travis: https://travis-ci.org/lightswitch05/kafka-node/builds/148936864
782222b to
1116e0a
Compare
|
Thanks for the PR @lightswitch05! I was thinking since one of the HLP's key feature is the automatic partitioning of messages maybe we can update the test to verify messages are produced to different partitions. I was thinking we can specify a |
|
Thanks for merging! I can definitely look into adding that extra test for |
|
I agree that adding coveralls would be a good idea. |
|
Yeah, lets do it! Just need to get @haio to activate it (or make me admin?) |
|
Added in #432 |
I added code coverage using istanbul. My tests were failing on Travis, after some research I found it was due to some changes with NPMv3 and peer dependencies with
eslint-config-semistandard. After getting that working, I sawHighLevelProducerwas in sore need of some tests, so I added those. They are pretty much the same test asProducer. Testing my changes some more with Travis I saw that proxyquire was not working, I changed the module require to a file to fix it.I would be happy to add integration with https://coveralls.io/ if there is any interest to have that level of code coverage information with pull requests. It would require the project owner to allow integration with the account.
Summary: Added code coverage. Added unit tests. Fixed tests on travis.