Fix tests for Travis CI