I am learning nodejs and I have a mongodb database with which i have to interact with. I am currently thinking of using mocha for a unit test framework and zombie.js for a acce
There are some
http://mongodb.github.com/node-mongodb-native/github/github.html#test-helpers-and-libraries
but you might want to just search on github or ask in the google group as well.
If your database access is a separate module, you can mock out the module or parts of the module (e.g., the configuration part) using one of the following:
The answers to the following related question lists a number of possible solutions/approaches: How do you mock MySQL (without an ORM) in Node.js?
In order to spin up a real in-memory mongodb for testing, https://github.com/nodkz/mongodb-memory-server helps as well.