Refactoring
Added unit tests, minor refactoring
Travis updates
Added docs