Fixed bug with tests hanging when run from rake. Added travis