Merge pull request #378 from koenpunt/ci

Added travis config, fixed tests for use on travis