Skip to content

Commit

Permalink
Merge pull request #641 from lucagiovagnoli/luca/fix-virtualenv-pytho…
Browse files Browse the repository at this point in the history
…n-tests-bug-640

Fix python test failure using virtualenv<20.0.0
  • Loading branch information
ancasarb authored Feb 19, 2020
2 parents 7a76df5 + e977ada commit 0e83927
Showing 1 changed file with 40 additions and 12 deletions.
52 changes: 40 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,50 @@ dist: trusty
services:
- docker

language: scala
scala:
- 2.11.8
jdk:
- oraclejdk8 # sbt +compile fails on jdk11 (xenial's default)

jobs:
include:
- stage: "Mleap tests"
name: "Scala Tests"
language: scala
script:
- travis/travis.sh

python:
- "2.7"
- "3.6"
- "3.7"
- name: "Python 2.7 tests"
language: python
python: 2.7
install:
- pip install "virtualenv<20.0.0" tox # Bug https://github.com/pypa/virtualenv/issues/1551
script:
- sbt +compile
- tox -c python/tox.ini -e py27 -v

install:
- pip install --user tox
script:
- travis/travis.sh
- tox -c python/tox.ini -e $(echo py$TRAVIS_PYTHON_VERSION | tr -d .) -v
- name: "Python 3.6 tests"
language: python
python: 3.6
install:
- pip install "virtualenv<20.0.0" tox # Bug https://github.com/pypa/virtualenv/issues/1551
script:
- sbt +compile
- tox -c python/tox.ini -e py36 -v

- name: "Python 3.7 tests"
language: python # This can't be java and python at the same time
python: 3.7
env:
# Required when not setting 'language: java' to force the correct jdk8
- PATH=$(echo "$PATH" | sed -e 's/:\/usr\/local\/lib\/jvm\/openjdk11\/bin//')
- JAVA_HOME="/usr/lib/jvm/java-1.8.0-openjdk-amd64"
dist: xenial # Travis won't install py37 on trusty
install:
- pip install "virtualenv<20.0.0" tox # Bug https://github.com/pypa/virtualenv/issues/1551
script:
- sbt +compile
- tox -c python/tox.ini -e py37 -v

notifications:
on_success: change
Expand All @@ -32,8 +62,6 @@ notifications:
on_success: change
on_failure: always

jdk:
- oraclejdk8
cache:
directories:
- $HOME/.ivy2/cache
Expand Down

0 comments on commit 0e83927

Please sign in to comment.