language: python matrix: include: # Linux - sudo: required services: - docker env: - "PYTHON=python2" - sudo: required services: - docker env: - "PYTHON=python3" # macOS - os: osx env: - "PYTHON=python2" - os: osx env: - "PYTHON=python3" script: - | if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then $PYTHON -m pip install -r requirements-dev.txt $PYTHON ./bin/run_tests.py else # linux test requires root to clean up the wheelhouse (docker runs as root) sudo $PYTHON -m ensurepip sudo $PYTHON -m pip install -r requirements-dev.txt sudo $PYTHON ./bin/run_tests.py fi