diff --git a/.travis.yml b/.travis.yml index b3c7623..47f82f7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -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 diff --git a/docs/release_notes.rst b/docs/release_notes.rst index 2ef00f9..da8d0f7 100644 --- a/docs/release_notes.rst +++ b/docs/release_notes.rst @@ -1,6 +1,10 @@ Release Notes ============= +v0.7.0 +------ +* Reserving version for py3 support in ambition + v0.6.0 ------ * Add python 3.6 support diff --git a/entity_event_slack/migrations/0001_initial.py b/entity_event_slack/migrations/0001_initial.py index 0855b78..8131d97 100644 --- a/entity_event_slack/migrations/0001_initial.py +++ b/entity_event_slack/migrations/0001_initial.py @@ -2,6 +2,7 @@ from __future__ import unicode_literals from django.db import models, migrations +import django.db.models.deletion class Migration(migrations.Migration): @@ -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)), diff --git a/entity_event_slack/version.py b/entity_event_slack/version.py index ef7eb44..1f356cc 100644 --- a/entity_event_slack/version.py +++ b/entity_event_slack/version.py @@ -1 +1 @@ -__version__ = '0.6.0' +__version__ = '1.0.0' diff --git a/requirements/requirements-testing.txt b/requirements/requirements-testing.txt new file mode 100644 index 0000000..073bc4f --- /dev/null +++ b/requirements/requirements-testing.txt @@ -0,0 +1,7 @@ +coverage +django-dynamic-fixture +django-nose +flake8 +freezegun +mock +psycopg2 diff --git a/setup.py b/setup.py index 7105129..d52c571 100755 --- a/setup.py +++ b/setup.py @@ -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', ], diff --git a/tox.ini b/tox.ini new file mode 100644 index 0000000..523073a --- /dev/null +++ b/tox.ini @@ -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