-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c5e98d2
commit 4f2e650
Showing
1 changed file
with
54 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
[tox] | ||
isolated_build = true | ||
skipsdist = true | ||
envlist = check, apply-check, docs, tests, build, changelog | ||
|
||
[testenv] | ||
allowlist_externals = poetry, ./test_keycloak_init.sh | ||
commands_pre = | ||
poetry install --sync | ||
|
||
[testenv:check] | ||
commands = | ||
black --check --diff src/keycloak tests docs | ||
isort -c --df src/keycloak tests docs | ||
flake8 src/keycloak tests docs | ||
codespell src tests docs | ||
|
||
[testenv:apply-check] | ||
commands = | ||
black -C src/keycloak tests docs | ||
black src/keycloak tests docs | ||
isort src/keycloak tests docs | ||
|
||
[testenv:docs] | ||
commands_pre = | ||
poetry install --no-root --sync -E docs | ||
commands = | ||
sphinx-build -T -E -W -b html -d _build/doctrees -D language=en ./docs/source _build/html | ||
|
||
[testenv:tests] | ||
setenv = file|tox.env | ||
passenv = CONTAINER_HOST,KEYCLOAK_DOCKER_IMAGE_TAG | ||
commands = | ||
./test_keycloak_init.sh "pytest -vv --cov=keycloak --cov-report term-missing {posargs}" | ||
|
||
[testenv:build] | ||
commands = | ||
poetry build --format sdist | ||
poetry build --format wheel | ||
|
||
[testenv:changelog] | ||
setenv = file|tox.env | ||
passenv = CONTAINER_HOST | ||
commands = | ||
cz changelog | ||
|
||
[flake8] | ||
max-line-length = 99 | ||
docstring-convention = all | ||
ignore = D203, D213, W503 | ||
docstring_style = sphinx | ||
|
||
[darglint] | ||
enable = DAR104 |