Refactor Travis config so that only the required PhantomJS version is downloaded for each build