-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathtox.ini
37 lines (32 loc) · 991 Bytes
/
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
# Tox (http://tox.testrun.org/) is a tool for running tests
# in multiple virtualenvs. This configuration file will run the
# test suite on all supported python versions. To use it, "pip install tox"
# and then run "tox" from this directory.
[tox]
envlist = py{36,37,38,39,310},flake8
skipsdist = True
skip_missing_interpreters = True
[testenv]
passenv = *
setenv =
LD_LIBRARY_PATH={env:PWD}/wdmd:{env:PWD}/src
SANLOCK_PRIVILEGED=0
SANLOCK_RUN_DIR=/tmp/sanlock
whitelist_externals = make
deps =
pytest
userstorage>=0.5.1
commands =
py{36,37,38,39,310}: make BUILDARGS="--build-lib={envsitepackagesdir}"
pytest {posargs}
[testenv:flake8]
deps = flake8
commands = flake8 --statistics tests python
[pytest]
# Notes:
# --basetemp: we must use /var/tmp as sanlock uses direct I/O.
# -rxX show extra test summary: (x)failed, (X)passed,
# --durations: show slowest test duration
addopts = -rxX --basetemp=/var/tmp/sanlock --durations=10
[flake8]
show_source = True