Updated Karma to run tests correctly.

This should fix the Travis-CI build failures.

- Added Coveralls support.
- Updated the current test to pass.