-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #43 from rachelhsmith/chore/37-get-tox-working
Get Tox Working
- Loading branch information
Showing
7 changed files
with
683 additions
and
1,221 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,27 @@ | ||
[tox] | ||
envlist = | ||
py{37,38,39,310}-dj{22,30,31,32,40} | ||
flake8 | ||
isort | ||
black | ||
envlist = py{38,39,310,311}-dj{22,30,31,32,40} | ||
skip_missing_interpreters = True | ||
isolated_build = True | ||
basepython = python3 | ||
|
||
[gh-actions] | ||
python = | ||
3.8: python3.8 | ||
3.9: python3.9 | ||
3.10: python3.10 | ||
3.11: python3.11 | ||
|
||
[testenv] | ||
allowlist_externals = pytest | ||
setenv = | ||
PYTHONPATH = {toxinidir} | ||
DJANGO_SETTINGS_MODULE = tests.settings | ||
deps = | ||
dj22: Django>=2.2,<2.3 | ||
dj30: Django>=3.0,<3.1 | ||
dj31: Django>=3.1,<3.2 | ||
dj32: Django>=3.2,<3.3 | ||
dj40: Django>=4.0,<4.1 | ||
|
||
install_command = pip install -U {opts} {packages} | ||
commands = | ||
; Install any dependencies that have changed since this | ||
; tox env was created. Installing in editable mode because it is faster. | ||
pip install -e . | ||
coverage run --source="{toxinidir}/tbxforms" -m django test {posargs:tbxforms} | ||
django-admin collectstatic --noinput | ||
django-admin check | ||
django-admin makemigrations --check --noinput | ||
coverage report -m --omit="{toxinidir}/tbxforms/tests/*" | ||
extras = testing | ||
|
||
[testenv:black] | ||
basepython = python3 | ||
commands = | ||
black --check ./ | ||
|
||
[testenv:flake8] | ||
basepython = python3 | ||
commands = | ||
flake8 tbxforms | ||
|
||
[testenv:isort] | ||
basepython = python3 | ||
usedevelop = false | ||
changedir = {toxinidir} | ||
dj32: Django>=3.2,<4.0 | ||
dj31: Django>=3.1,<3.2 | ||
dj30: Django>=3.0,<3.1 | ||
dj22: Django>=2.2,<2.3 | ||
extras = test | ||
commands = | ||
isort --recursive --check-only --diff tbxforms | ||
pytest |