Skip to content

Commit

Permalink
Merge pull request #19 from wesokes/develop
Browse files Browse the repository at this point in the history
tox
  • Loading branch information
somewes authored Apr 20, 2018
2 parents d422cdc + d6f7f99 commit a3d99c7
Show file tree
Hide file tree
Showing 6 changed files with 78 additions and 25 deletions.
52 changes: 35 additions & 17 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,45 @@
sudo: false
language: python

sudo: false

python:
- '2.7'
- '3.4'
- '3.5'
- '3.6'
- "2.7"
- "3.4"
- "3.5"
- "3.6"

env:
global:
- DB=postgres
matrix:
- DJANGO=">=1.9,<1.10"
- DJANGO=">=1.10,<1.11"
- DJANGO=">=1.11,<2.0"
- DJANGO=1.11
- DJANGO=2.0
- DJANGO=master

addons:
postgresql: '9.5'

matrix:
include:
- { python: "3.6", env: TOXENV=flake8 }

exclude:
- { python: "2.7", env: DJANGO=master }
- { python: "2.7", env: DJANGO=2.0 }
- { python: "3.4", env: DJANGO=master }

allow_failures:
- env: DJANGO=master

install:
- pip install -q coveralls coverage flake8 Django$DJANGO django-nose>=1.4
- pip install -r requirements/docs.txt
- pip install tox-travis

before_script:
- psql -c 'CREATE DATABASE entity_event_slack;' -U postgres

script:
- flake8 .
- coverage run setup.py test
- coverage report --fail-under=100
- python setup.py install
- python setup.py build_sphinx
- tox

after_success:
coveralls

notifications:
email: false
3 changes: 2 additions & 1 deletion entity_event_slack/migrations/0001_initial.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from __future__ import unicode_literals

from django.db import models, migrations
import django.db.models.deletion


class Migration(migrations.Migration):
Expand All @@ -14,7 +15,7 @@ class Migration(migrations.Migration):
migrations.CreateModel(
name='SlackMedium',
fields=[
('medium_ptr', models.OneToOneField(serialize=False, to='entity_event.Medium', auto_created=True, primary_key=True, parent_link=True)),
('medium_ptr', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, serialize=False, to='entity_event.Medium', auto_created=True, primary_key=True, parent_link=True)),
('api_token', models.TextField()),
('channel', models.TextField()),
('creation_time', models.DateTimeField(auto_now_add=True)),
Expand Down
2 changes: 1 addition & 1 deletion entity_event_slack/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '0.7.0'
__version__ = '1.0.0'
7 changes: 7 additions & 0 deletions requirements/requirements-testing.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
coverage
django-dynamic-fixture
django-nose
flake8
freezegun
mock
psycopg2
11 changes: 5 additions & 6 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,16 @@ def get_version():
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Framework :: Django',
'Framework :: Django :: 1.9',
'Framework :: Django :: 1.10',
'Framework :: Django :: 1.11',
'Framework :: Django :: 2.0',
],
license='MIT',
install_requires=[
'celery>=3.1,<4.0',
'Django>=1.9',
'django-db-mutex>=0.5.0',
'django-entity-event>=0.8.0',
'django-manager-utils>=0.13.0',
'Django>=1.11',
'django-db-mutex>=1.1.0',
'django-entity-event>=1.1.0',
'django-manager-utils>=1.1.1',
'pyslack>=0.1.3',
'requests',
],
Expand Down
28 changes: 28 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
[tox]
envlist =
flake8
py{27,34,35,36}-django111
py{34,35,36}-django20
py{35,36}-djangomaster

[testenv]
setenv =
DB = postgres
deps =
django111: Django>=1.11,<2.0
django20: Django>=2.0,<2.1
djangomaster: https://github.com/django/django/archive/master.tar.gz
-rrequirements/requirements-testing.txt
commands =
coverage run setup.py test
coverage report --fail-under=100

[testenv:flake8]
deps = flake8
commands = flake8 entity_event_slack

[travis:env]
DJANGO =
1.11: django111
2.0: django20
master: djangomaster

0 comments on commit a3d99c7

Please sign in to comment.