Unify travis and tox configs
Fixes #489. Adapted from config I use on my own projects, e.g. [Django-MySQL .travis.yml](https://github.com/adamchainz/django-mysql/blob/master/.travis.yml).
This commit is contained in:
parent
e40e45e38b
commit
1c82b866c2
45
.travis.yml
45
.travis.yml
|
@ -1,45 +1,16 @@
|
|||
language: python
|
||||
|
||||
sudo: false
|
||||
|
||||
language: python
|
||||
python: '3.5'
|
||||
cache: pip
|
||||
|
||||
python:
|
||||
- "2.7"
|
||||
- "3.3"
|
||||
- "3.4"
|
||||
- "3.5"
|
||||
|
||||
env:
|
||||
- DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
|
||||
- DJANGO="django>=1.10.0,<1.11.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
|
||||
- DJANGO="django>=1.9.0,<1.10.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
|
||||
- DJANGO="django>=1.8.0,<1.9.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
|
||||
- DJANGO="django>=1.8.0,<1.9.0" REST_FRAMEWORK="djangorestframework>=3.3,<3.4"
|
||||
|
||||
install:
|
||||
- travis_retry pip install -Ur requirements/test-ci.txt
|
||||
- travis_retry pip install $DJANGO $REST_FRAMEWORK
|
||||
- pip install tox
|
||||
|
||||
script:
|
||||
- $W coverage run --source django_filters runtests.py -v 2
|
||||
- coverage erase
|
||||
- tox
|
||||
|
||||
after_success:
|
||||
- coverage combine
|
||||
- coverage report
|
||||
|
||||
notifications:
|
||||
email: false
|
||||
|
||||
matrix:
|
||||
exclude:
|
||||
- python: "3.3"
|
||||
env: DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
|
||||
- python: "3.3"
|
||||
env: DJANGO="django>=1.10.0,<1.11.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
|
||||
- python: "3.3"
|
||||
env: DJANGO="django>=1.9.0,<1.10.0" REST_FRAMEWORK="djangorestframework>=3.4,<3.5"
|
||||
include:
|
||||
- python: "3.5"
|
||||
env: W='python -W error -m' DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
|
||||
allow_failures:
|
||||
- env: W='python -W error -m' DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
|
||||
- env: DJANGO='https://github.com/django/django/archive/master.tar.gz' REST_FRAMEWORK='djangorestframework>=3.4,<3.5'
|
||||
fast_finish: true
|
||||
|
|
18
tox.ini
18
tox.ini
|
@ -6,14 +6,7 @@ envlist =
|
|||
|
||||
|
||||
[testenv]
|
||||
basepython =
|
||||
py27: python2.7
|
||||
py33: python3.3
|
||||
py34: python3.4
|
||||
py35: python3.5
|
||||
|
||||
|
||||
commands = ./runtests.py {posargs}
|
||||
commands = coverage run --source django_filters ./runtests.py {posargs}
|
||||
setenv =
|
||||
PYTHONDONTWRITEBYTECODE=1
|
||||
deps =
|
||||
|
@ -24,3 +17,12 @@ deps =
|
|||
restframework33: djangorestframework>=3.3,<3.4
|
||||
restframework34: djangorestframework>=3.4,<3.5
|
||||
-rrequirements/test-ci.txt
|
||||
|
||||
[testenv:py27-django-latest-restframework34]
|
||||
ignore_outcome = True
|
||||
|
||||
[testenv:py34-django-latest-restframework34]
|
||||
ignore_outcome = True
|
||||
|
||||
[testenv:py35-django-latest-restframework34]
|
||||
ignore_outcome = True
|
||||
|
|
Loading…
Reference in New Issue