Skip to content

Commit

Permalink
Update test environment
Browse files Browse the repository at this point in the history
 - Add python 3.6
 - Drop Python 3.4
 - Use tox on travis
  • Loading branch information
codingjoe committed Dec 28, 2016
1 parent ca405c0 commit bc36e44
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 22 deletions.
26 changes: 14 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,31 @@ cache:
- pip
python:
- "2.7"
- "3.4"
- "3.5"
- "3.6"
env:
global:
- DISPLAY=:99.0
matrix:
- DJANGO="Django<1.9,>=1.8"
- DJANGO="Django<1.10,>=1.9"
- DJANGO="-e git+https://github.com/django/django.git@master#egg=Django"
- TOXENV=qa
- DJANGO=18
- DJANGO=19
- DJANGO=110
- DJANGO=master
matrix:
fast_finish: true
allow_failures:
- env: DJANGO="-e git+https://github.com/django/django.git@master#egg=Django"
- env: DJANGO=master
install:
- pip install --upgrade pip
- pip install -r requirements-dev.txt
- pip install $DJANGO
- pip install --upgrade pip tox
- pip install -U coveralls
- sh -e /etc/init.d/xvfb start
script:
- isort --check-only --recursive --diff .
- flake8 --jobs=2 .
- pep257 s3file
- coverage run --source=s3file -m 'pytest'
- |
if [[ $TOXENV == qa ]]; then
tox -e qa
else
tox -e py$(echo $TRAVIS_PYTHON_VERSION | sed -e 's/\.//g')-dj$DJANGO
fi
after_success:
- coveralls
6 changes: 2 additions & 4 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,17 @@
# pip-compile requirements-dev.in
#
-e .
coverage==4.3
django-appconf==1.0.2
flake8==3.2.1
isort==4.2.5
mccabe==0.5.2 # via flake8
pep257==0.7.0
pep8-naming==0.4.1
pep8==1.7.0 # via flake8
pluggy==0.4.0 # via tox
py==1.4.31 # via pytest, tox
py==1.4.31 # via pytest
pyflakes==1.3.0 # via flake8
pytest-django==3.1.2
pytest==3.0.5
selenium==3.0.2
six==1.10.0 # via django-appconf
tox==2.5.0
virtualenv==15.1.0 # via tox
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[pytest]
[tool:pytest]
addopts = --tb=short -rxs
DJANGO_SETTINGS_MODULE=tests.testapp.settings
norecursedirs = env docs
Expand Down
11 changes: 6 additions & 5 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
[tox]
envlist = py{27,34,35}-django{18,19,master},qa
envlist = py{27,35,36}-dj{18,19,110,master},qa
[testenv]
setenv=
DISPLAY=:99.0
PYTHONPATH = {toxinidir}
deps=
-rrequirements-dev.txt
django18: Django>=1.8,<1.9
django19: Django>=1.9,<1.10
djangomaster: -egit+https://github.com/django/django.git@master#egg=Django
dj18: https://github.com/django/django/archive/stable/1.8.x.tar.gz#egg=django
dj19: https://github.com/django/django/archive/stable/1.9.x.tar.gz#egg=django
dj110: https://github.com/django/django/archive/stable/1.10.x.tar.gz#egg=django
djmaster: https://github.com/django/django/archive/master.tar.gz#egg=django
commands=
py.test \
coverage run --source=s3file -m 'pytest' \
--basetemp={envtmpdir} \
--ignore=.tox \
{posargs}
Expand Down

0 comments on commit bc36e44

Please sign in to comment.