fixed tests which causes trouble on travis

This is still a work-in-progress. Only submitting PR to see how travis behaves.