HackThis/NexBot — pull request #83 by verath (2014-06-27 11:59:08+00:00)
Title: Coveralls test coverage

A bunch of changes to integrate the project with coveralls.io for test coverage. All the cool kids does this. See https://coveralls.io/builds/909935 for an example.

Firstly, all the source code has been moved into a new directory /src. This makes it a lot easier to run the instrumentation for the coverage as one can specify /src as the source directory. It also makes sense to have the source code in a sub-directory, I think?

The data directory was not moved into ./src. References to this folder has been updated (it should have been only in main.js). Other than that all paths should be either relative or for node_modules, both of which should still work the same. The change means the command to run NexBot would be `node src/main.js` instead of `node main.js`.

Other than that minor change *cough* there should have been no changes to any code. There are quite major changes to the various config files however. Most of the changes are explained somewhat at https://github.com/pghalliday/grunt-mocha-test#instrumenting-source-files-with-coverage-data-before-running-tests.

After merging there are a few steps required to enable coveralls;
1. Go to https://coveralls.io/ and sign in using github.
2. Go to https://coveralls.io/repos/new and enable NexBot.
3. ???
4. Profit (well, a coverage badge on the readme)