Moved all tests to using mocha.

* Added devDependencies
* Generate mocha tests dynamically from old json cases

Also all test code validates using nodelint