-
Notifications
You must be signed in to change notification settings - Fork 7
/
tox.ini
72 lines (62 loc) · 1.68 KB
/
tox.ini
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
[tox]
envlist = test,test-all,test-dbapi,test-unit,black,black-format,style,coverage
minversion = 4.2.6
skipsdist = True
ignore_basepython_conflict = true
[testenv]
usedevelop = True
install_command = pip install {opts} {packages}
setenv =
PYTHONPATH = {env:PYTHONPATH}{:}{toxinidir}
deps =
-r{toxinidir}/test-requirements.txt
[testenv:test]
ignore_errors = True
commands =
docker-compose up -d
python {toxinidir}/wait_container_ready.py
pytest -v {posargs}
docker-compose down
[testenv:test-all]
ignore_errors = True
commands =
docker-compose up -d
python {toxinidir}/wait_container_ready.py
pytest -v test --dbdriver ydb --dbdriver ydb_async
pytest -v ydb_sqlalchemy
docker-compose down -v
[testenv:test-unit]
commands =
pytest -v {toxinidir}/ydb_sqlalchemy
[testenv:coverage]
ignore_errors = True
commands =
docker-compose up -d
python {toxinidir}/wait_container_ready.py
pytest -v --cov-report html:cov_html --cov=ydb_sqlalchemy {posargs}
docker-compose down
[testenv:black]
skip_install = true
commands =
black --diff --check ydb_sqlalchemy examples/basic_example test
[testenv:black-format]
skip_install = true
commands =
black ydb_sqlalchemy examples/basic_example test
[testenv:isort]
skip_install = true
commands =
isort ydb_sqlalchemy examples/basic_example test
[testenv:style]
ignore_errors = True
commands =
flake8 ydb_sqlalchemy examples/basic_example test
[flake8]
show-source = true
builtins = _
max-line-length = 120
ignore=E203,W503
per-file-ignores =
ydb_sqlalchemy/__init__.py: F401
ydb_sqlalchemy/sqlalchemy/compiler/__init__.py: F401
exclude=*_pb2.py,*_grpc.py,.venv,.git,.tox,dist,doc,*egg,docs/*