Updates Test Configuration, Narrows Dependency Declaration

This commit is contained in:
Michael 2020-11-11 10:23:55 -06:00
parent dad5bca1cb
commit 7ce1a47b4c
6 changed files with 33 additions and 34 deletions

View File

@ -3,45 +3,44 @@ orbs:
docker: circleci/docker@0.6.0 docker: circleci/docker@0.6.0
jobs: jobs:
test-django-3: &template test:
docker: docker:
- image: circleci/python:3.8.0 - image: circleci/python:3.8.0
environment:
DJANGO_VERSION: 3.1
DRF: 3.11.1
executor: docker/docker executor: docker/docker
steps: steps:
- checkout - checkout
- run: - run:
command: pip install --user Django==$DJANGO_VERSION djangorestframework==$DRF command: pip install --user tox coverage coveralls
name: "Pip install version-specific Django + DRF" name: "Install Tox & Coverage"
- run: - run:
command: pip install --user -r dj_rest_auth/tests/requirements.pip command: tox
name: "Pip Install test requirements" name: "Run Tox on All Supported Django and Python Versions"
- run: - run:
command: | command: |
mkdir -p test-results/ mkdir -p test-results/
coverage run --source=dj_rest_auth setup.py test tox -e coverage
coverage report name: "Generate Coverage Report"
name: Test
- run: - run:
command: COVERALLS_REPO_TOKEN=Q58WdUuZOi89XHyDeDsGE2lxUGQ2IfqP3 coveralls command: COVERALLS_REPO_TOKEN=Q58WdUuZOi89XHyDeDsGE2lxUGQ2IfqP3 coveralls
name: Coverage name: "Send results to Coveralls"
- store_test_results:
path: test-results/
build:
docker:
- image: circleci/python:3.8.0
executor: docker/docker
steps:
- checkout
- run: - run:
command: python3 setup.py sdist command: python3 setup.py sdist
name: Build name: Build
- store_test_results:
path: test-results/
- store_artifacts: - store_artifacts:
path: dist/ path: dist/
test-django-2:
<<: *template
environment:
DJANGO_VERSION: 2.2.10
DRF: 3.9
workflows: workflows:
main: main:
jobs: jobs:
- test-django-3 - test
- test-django-2 - build:
requires:
- test

View File

@ -7,7 +7,7 @@ Drop-in API endpoints for handling authentication securely in Django Rest Framew
with SPAs (e.g React, Vue, Angular), and Mobile applications. with SPAs (e.g React, Vue, Angular), and Mobile applications.
## Requirements ## Requirements
- Django 2 or 3. - Django 2 or 3 (<3.1)
- Python 3 - Python 3
## Quick Setup ## Quick Setup

View File

@ -1,7 +1,7 @@
__title__ = 'dj-rest-auth' __title__ = 'dj-rest-auth'
__description__ = 'Authentication and Registration in Django Rest Framework.' __description__ = 'Authentication and Registration in Django Rest Framework.'
__url__ = 'http://github.com/jazzband/dj-rest-auth' __url__ = 'http://github.com/jazzband/dj-rest-auth'
__version__ = '1.1.2' __version__ = '2.0.0'
__author__ = '@iMerica https://github.com/iMerica' __author__ = '@iMerica https://github.com/iMerica'
__author_email__ = 'imichael@pm.me' __author_email__ = 'imichael@pm.me'
__license__ = 'MIT' __license__ = 'MIT'

View File

@ -1,6 +1,6 @@
django-allauth>=0.25.0 django-allauth==0.42.0
responses>=0.5.0 responses==0.10.0
flake8==2.4.0 flake8==2.4.0
djangorestframework-simplejwt==4.4.0 djangorestframework-simplejwt==4.4.0
unittest-xml-reporting>=3.0.2 unittest-xml-reporting==3.0.2
coveralls>=1.11.1 coveralls==1.11.1

View File

@ -27,16 +27,16 @@ setup(
keywords='django rest auth registration rest-framework django-registration api', keywords='django rest auth registration rest-framework django-registration api',
zip_safe=False, zip_safe=False,
install_requires=[ install_requires=[
'Django>=2.0', 'Django>=2.0,<3.1',
'djangorestframework>=3.7.0', 'djangorestframework>=3.7.0',
], ],
extras_require={ extras_require={
'with_social': ['django-allauth>=0.25.0'], 'with_social': ['django-allauth>=0.40.0,<0.43.0'],
}, },
tests_require=[ tests_require=[
'unittest-xml-reporting>=3.0.2', 'unittest-xml-reporting>=3.0.2',
'responses>=0.5.0', 'responses>=0.5.0',
'django-allauth>=0.25.0', 'django-allauth==0.40.0',
'djangorestframework-simplejwt>=4.4.0 ', 'djangorestframework-simplejwt>=4.4.0 ',
'coveralls>=1.11.1' 'coveralls>=1.11.1'
], ],

View File

@ -10,16 +10,16 @@
[tox] [tox]
skipsdist = true skipsdist = true
envlist = envlist =
python{3.5,3.6,3.7,3.8}-django22 python{3.5,3.6,3.7,3.8,3.9}-django2
python{3.6,3.7,3.8}-django31 python{3.6,3.7,3.8,3.9}-django3
[testenv] [testenv]
commands = commands =
python ./runtests.py python ./runtests.py
deps = deps =
-rdj_rest_auth/tests/requirements.pip -rdj_rest_auth/tests/requirements.pip
django22: Django>=2.2,<2.3 django2: Django>=2.2,<2.3
django31: Django>=3.1 django3: Django>=3.0,<3.1
# Configuration for coverage and flake8 is being set in `./setup.cfg` # Configuration for coverage and flake8 is being set in `./setup.cfg`
[testenv:coverage] [testenv:coverage]