diff --git a/.travis.yml b/.travis.yml index 2f78daab..943042b1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,8 +7,9 @@ python: - "3.8" - "3.9" install: - - pip install -q -U pip tox tox-travis python-coveralls + - pip install -q -U pip tox tox-travis + - pip install -e .[dev] script: - tox after_success: - - coveralls + - bash <(curl -s https://codecov.io/bash) diff --git a/django_summernote/__init__.py b/django_summernote/__init__.py index 4f3fa5f8..a3ff65bc 100644 --- a/django_summernote/__init__.py +++ b/django_summernote/__init__.py @@ -4,6 +4,10 @@ __project__ = PROJECT = 'django-summernote' __author__ = AUTHOR = "django-summernote contributors" -from django import VERSION as django_version -if django_version < (3, 2): - default_app_config = 'django_summernote.apps.DjangoSummernoteConfig' +try: + from django import VERSION as django_version + if django_version < (3, 2): + default_app_config = 'django_summernote.apps.DjangoSummernoteConfig' +except ModuleNotFoundError: + # This part is needed for setup.py + pass diff --git a/tox.ini b/tox.ini index dfd7677b..eaf89ca0 100644 --- a/tox.ini +++ b/tox.ini @@ -20,8 +20,6 @@ deps = pytest pytest-django coverage - django-dummy-plug - bleach dj202: Django<2.3 dj300: Django<3.1