mocha.js based unit test example (support console and browser)