Skip to content

Commit

Permalink
Install tox in a virtualenv
Browse files Browse the repository at this point in the history
Since TravisCI has an extremely old version of PyPy, we need to use
pyenv to install a more recent version. However, pyenv's shims don't
persist between the install and script portions of Travis. So we have to
use a virtualenv so Travis can find the tox command.
  • Loading branch information
sigmavirus24 committed Nov 23, 2016
1 parent 2414cad commit d2f0bc2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,5 @@ install:
- ./.travis/install.sh

script:
- source ~/.venv/bin/activate
- tox
6 changes: 3 additions & 3 deletions .travis/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ if [[ "${TOXENV}" = pypy* ]]; then
pyenv install "pypy-$PYPY_VERSION"
pyenv global "pypy-$PYPY_VERSION"

pip install --upgrade tox

pyenv rehash
fi


python -m pip install --upgrade virtualenv
python -m virtualenv ~/.venv
source ~/.venv/bin/activate
pip install --upgrade tox

0 comments on commit d2f0bc2

Please sign in to comment.