Skip to content

Commit b50df6b

Browse files
authored
Update test suite (#41)
1 parent f8a15e8 commit b50df6b

File tree

6 files changed

+62
-59
lines changed

6 files changed

+62
-59
lines changed

.travis.yml

Lines changed: 52 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,69 @@
11
language: python
22
sudo: false
33
dist: trusty
4+
cache:
5+
- apt
6+
- pip
7+
services:
8+
- redis
49
addons:
5-
firefox: latest
6-
apt:
10+
firefox: latest
11+
apt:
712
sources:
8-
- google-chrome
13+
- google-chrome
914
packages:
10-
- google-chrome-stable
11-
cache:
12-
- pip
13-
- apt
15+
- google-chrome-stable
1416
python:
15-
- "2.7"
16-
- "3.5"
17-
- "3.6"
17+
- '2.7'
18+
- '3.5'
19+
- '3.6'
1820
env:
1921
global:
20-
- DISPLAY=:99.0
22+
- DISPLAY=:99.0
23+
- GECKO_DRIVER_VERSION=v0.16.1
24+
- CHROME_DRIVER_VERSION=2.29
2125
matrix:
22-
- TOXENV=qa
23-
- DJANGO=18
24-
- DJANGO=19
25-
- DJANGO=110
26-
- DJANGO=master
26+
- DJANGO=18
27+
- DJANGO=110
28+
- DJANGO=111
29+
- DJANGO=master
30+
- TOXENV=qa
2731
matrix:
2832
fast_finish: true
2933
allow_failures:
30-
- env: DJANGO=master
34+
- env: DJANGO=master
35+
exclude:
36+
- env: DJANGO=master
37+
python: '2.7'
38+
- env: TOXENV=qa
39+
python: '2.7'
40+
- env: TOXENV=qa
41+
python: '3.5'
3142
install:
32-
- pip install --upgrade pip tox
33-
- pip install -U coveralls
34-
- sh -e /etc/init.d/xvfb start
43+
- pip install --upgrade pip tox
44+
- pip install -U coveralls
45+
- sh -e /etc/init.d/xvfb start
3546
before_script:
36-
- mkdir bin
37-
- curl -O https://chromedriver.storage.googleapis.com/2.27/chromedriver_linux64.zip
38-
- unzip chromedriver_linux64.zip -d bin
39-
- curl -Lo geckodriver.tar.gz https://github.com/mozilla/geckodriver/releases/download/v0.11.1/geckodriver-v0.11.1-linux64.tar.gz
40-
- tar xzf geckodriver.tar.gz -C bin
41-
- PATH=$PATH:$PWD/bin
42-
- nvm install --lts
43-
- npm install -g standard
47+
- mkdir bin
48+
- curl -O https://chromedriver.storage.googleapis.com/${CHROME_DRIVER_VERSION}/chromedriver_linux64.zip
49+
- unzip chromedriver_linux64.zip -d bin
50+
- curl -Lo - "https://github.com/mozilla/geckodriver/releases/download/${GECKO_DRIVER_VERSION}/geckodriver-${GECKO_DRIVER_VERSION}-linux64.tar.gz" | tar xzf - -C bin
51+
- PATH=$PATH:$PWD/bin
52+
- |
53+
if [[ -z $TOXENV ]]; then
54+
export TOXENV=py$(echo $TRAVIS_PYTHON_VERSION | sed -e 's/\.//g')-dj$DJANGO
55+
fi
56+
- echo $TOXENV
4457
script:
45-
- |
46-
if [[ $TOXENV == qa ]]; then
47-
tox -e qa
48-
else
49-
tox -e py$(echo $TRAVIS_PYTHON_VERSION | sed -e 's/\.//g')-dj$DJANGO
50-
fi
51-
- standard
58+
- tox -e $TOXENV
5259
after_success:
53-
- coveralls
60+
- coveralls
61+
deploy:
62+
provider: pypi
63+
user: codingjoe
64+
password:
65+
secure: OzNShO+N3zL3LIyJ7Fu/TFgJTaI+FlZxLItjPTu5tAfvrxPWmKXJkA7b8znx5O2w0kSynk0R1Ddyd6Ri4AIyS5SGm2ZbvrTyIpaXPvWMBl1o8X/nH14f61HP2piEtnk24FBLTbublgC9N1G4w/166jAwv2dxS9aWJGioAlSOgH8=
66+
on:
67+
tags: true
68+
distributions: sdist bdist_wheel
69+
repo: codingjoe/django-s3file

MANIFEST.in

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
11
include README.md
2-
recursive-include s3file *
2+
recursive-include s3file *
3+
4+
[bdist_wheel]
5+
universal=1

requirements-dev.txt

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,7 @@
1-
#
2-
# This file is autogenerated by pip-compile
3-
# Make changes in requirements-dev.in, then run this to update:
4-
#
5-
# pip-compile requirements-dev.in
6-
#
71
-e .
82
coverage==4.4.1
9-
django-appconf==1.0.2
10-
flake8==3.3.0
113
isort==4.2.5
12-
mccabe==0.6.1 # via flake8
13-
pydocstyle==2.0.0
14-
pep8-naming==0.4.1
15-
pep8==1.7.0 # via flake8
16-
py==1.4.33 # via pytest
17-
pyflakes==1.5.0 # via flake8
4+
py==1.4.33
185
pytest-django==3.1.2
196
pytest==3.0.7
20-
selenium==3.3.3
21-
six==1.10.0 # via django-appconf
7+
selenium==3.4.2

setup.cfg

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@ addopts = --tb=short -rxs
33
DJANGO_SETTINGS_MODULE=tests.testapp.settings
44
norecursedirs = env docs
55

6-
[flake8]
6+
[pycodestyle]
77
max-line-length = 99
8-
max-complexity = 10
98
statistics = true
109
show-source = true
1110
exclude = */migrations/*,docs/*,env/*,.tox/*

tests/conftest.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ def driver(request):
2929
pytest.skip(force_text(e))
3030
else:
3131
b.set_window_size(1200, 800)
32+
b.implicitly_wait(0.1)
3233
yield b
3334
if isinstance(b, webdriver.Chrome):
3435
# chrome needs a couple of seconds before it can be quit

tox.ini

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[tox]
2-
envlist = py{27,35,36}-dj{18,19,110,master},qa
2+
envlist = py{27,35,36}-dj{18,110,111,master},qa
33
[testenv]
44
setenv=
55
DISPLAY=:99.0
66
PYTHONPATH = {toxinidir}
77
deps=
88
-rrequirements-dev.txt
99
dj18: https://github.com/django/django/archive/stable/1.8.x.tar.gz#egg=django
10-
dj19: https://github.com/django/django/archive/stable/1.9.x.tar.gz#egg=django
1110
dj110: https://github.com/django/django/archive/stable/1.10.x.tar.gz#egg=django
11+
dj111: https://github.com/django/django/archive/stable/1.11.x.tar.gz#egg=django
1212
djmaster: https://github.com/django/django/archive/master.tar.gz#egg=django
1313
commands=
1414
coverage run --source=s3file -m 'pytest' \
@@ -22,5 +22,3 @@ deps=
2222
-rrequirements-dev.txt
2323
commands=
2424
isort --check-only --recursive --diff {posargs}
25-
flake8 --jobs=2 {posargs}
26-
pydocstyle --verbose --explain --source --count {posargs}

0 commit comments

Comments
 (0)