Add rules folder as part of the linting process

This includes the src/rules folder as part of the linting process for
the library. This means that when you run `npm test` it will now also
lint src/rules.

Also fixes errors being generated from CoffeeScript files in the rules
folder.

Note there are now 2 more warnings for cyclomatic complexity.