зеркало из https://github.com/mozilla/treeherder.git
53 строки
1.3 KiB
INI
53 строки
1.3 KiB
INI
[tox]
|
|
envlist = py37
|
|
isolated_build = true
|
|
skipsdist=True
|
|
|
|
toxworkdir={toxinidir}/.tox
|
|
|
|
[testenv]
|
|
whitelist_externals =
|
|
sh
|
|
docker-compose
|
|
commands_pre =
|
|
docker-compose up --detach mysql redis rabbitmq
|
|
pip install -r {toxinidir}/requirements/dev.txt
|
|
pip install -r {toxinidir}/requirements/common.txt
|
|
commands =
|
|
{toxinidir}/manage.py check
|
|
sh -c "SITE_URL=https://treeherder.dev TREEHERDER_DEBUG=False ./manage.py check --deploy --fail-level WARNING"
|
|
# Running slow tests (DB required)
|
|
pytest tests/ --runslow
|
|
commands_post =
|
|
# This is to deal with running the containers with --detached
|
|
docker-compose down
|
|
|
|
[testenv:linters]
|
|
commands_pre =
|
|
pip install -r {toxinidir}/requirements/dev.txt
|
|
pip install -r {toxinidir}/requirements/common.txt
|
|
commands =
|
|
pip check
|
|
# This ensures that we don't loose the ability of installing locally pre-commit checks
|
|
pre-commit run --all-files
|
|
commands_post =
|
|
|
|
[testenv:docs]
|
|
commands_pre =
|
|
pip install poetry
|
|
poetry install --extras "docs"
|
|
commands =
|
|
mkdocs build
|
|
commands_post =
|
|
|
|
[testenv:docker]
|
|
whitelist_externals=
|
|
docker-compose
|
|
commands_pre =
|
|
docker-compose build
|
|
commands =
|
|
docker-compose run -e TREEHERDER_DEBUG=False backend bash -c "pytest --cov --cov-report=xml tests/ --runslow"
|
|
|
|
[flake8]
|
|
per-file-ignores = treeherder/model/models.py:E402
|