fixing tests so that they run correctly on TravisCI and allow for the directory they run in to be dynamic