adding test cases. updated mocha.js. 1 spelling fix in common/rules.js