diff options
author | Erik Skultety <eskultet@redhat.com> | 2023-03-24 16:34:28 +0100 |
---|---|---|
committer | Daniel P. Berrangé <berrange@redhat.com> | 2023-04-28 10:05:23 +0000 |
commit | f749956f3bd6d7aa15ae49a37706d0d27fdeb63a (patch) | |
tree | 53a2bb5a1e5c9803c6cc7c167884aa1a9e739d7e | |
parent | 073c7beb53d1174fec9620433adacee850ddd3ed (diff) | |
download | libvirt-ci-f749956f3bd6d7aa15ae49a37706d0d27fdeb63a.zip libvirt-ci-f749956f3bd6d7aa15ae49a37706d0d27fdeb63a.tar.gz libvirt-ci-f749956f3bd6d7aa15ae49a37706d0d27fdeb63a.tar.bz2 |
Add tox.ini configuration file
This defines 3 test environments:
1) flake8 linter
2) one for python 3.8 as that's our base
3) one for python 3.11 (or whatever is the newest version) to check for
future deprecation warnings
It also instructs tox to always build wheels out of our package instead
of sdists. This is beneficial as tox's virtual environments are re-used
in between runs, so with no code changes, the same wheel will be used
and installed.
Signed-off-by: Erik Skultety <eskultet@redhat.com>
-rw-r--r-- | tox.ini | 20 |
1 files changed, 20 insertions, 0 deletions
@@ -0,0 +1,20 @@ +[tox] +isolated_build = True +envlist = py3{8,11}, lint + +[testenv] +package = wheel +wheel_build_env = .pkg + +[testenv:py3{8,11}] +description = Run pytest +deps = pytest + ansible + ansible-runner + -rrequirements.txt +commands = pytest + +[testenv:lint] +description = Run linter +deps = flake8 +commands = flake8 --format=pylint lcitool |