Adding test and optimizing travis configuration