code clean up + switching to thread pool testing on Travis CI