-
Notifications
You must be signed in to change notification settings - Fork 9
/
tox.ini
53 lines (46 loc) · 1.13 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
[tox]
envlist = flake8,black,mypy,docs,py39,py310,py311,py312,py313
isolated_build = True
[testenv]
deps =
pytest
coverage
commands =
coverage run -m pytest
coverage combine
coverage xml
coverage report
setenv = PYTHONDEVMODE = 1
[testenv:flake8]
basepython = python3.10
deps = flake8
commands = flake8 src/ tests/
[testenv:black]
basepython = python3.10
deps = black==22.3.0
skip_install = true
commands = black --check src/ tests/ doc/ helpers/ setup.py
[testenv:mypy]
basepython = python3.10
deps =
mypy
pytest
commands = mypy src/ tests/
[testenv:asan]
setenv=
PYTHONDEVMODE=1
PYTHONMALLOC=malloc
CFLAGS=-lasan -fsanitize=address -fno-omit-frame-pointer
allowlist_externals=bash
commands=
bash -c 'export LD_PRELOAD=$(gcc -print-file-name=libasan.so) && printenv LD_PRELOAD && python -c "import dnaio" && pytest tests'
[testenv:docs]
basepython = python3.10
changedir = doc
deps = -r doc/requirements.txt
commands = sphinx-build -W -d {envtmpdir}/doctrees . {envtmpdir}/html
[flake8]
max-line-length = 99
max-complexity = 15
# E203 (whitespace before ':') must be ignored for Black
extend-ignore = E203