Adding Travis CI and fixing tests