From 861f79d46397d8bbc5b55b95bc4ca2ac0fb1f247 Mon Sep 17 00:00:00 2001 From: Cédric Ollivier Date: Fri, 1 Jul 2022 09:49:58 +0200 Subject: Update to Alpine 3.16 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It also switches to pytest because nose fails vs py3.10. Change-Id: I920baef12d4934b359873519d5518835007c2f02 Signed-off-by: Cédric Ollivier --- tox.ini | 42 ++++++++++++++++++------------------------ 1 file changed, 18 insertions(+), 24 deletions(-) (limited to 'tox.ini') diff --git a/tox.ini b/tox.ini index c09e942d..d6924538 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = docs,pep8,pylint,yamllint,bashate,py39,cover,perm +envlist = docs,pep8,pylint,yamllint,bashate,py310,cover,perm skipsdist = True [testenv] @@ -11,33 +11,32 @@ deps = -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt install_command = pip install {opts} {packages} -commands = nosetests --with-xunit \ - --with-coverage \ - --cover-tests \ - --cover-package=xtesting \ - --cover-xml \ - --cover-html \ - xtesting/tests/unit +commands = + pytest xtesting/tests/unit \ + --junit-xml=junit.xml \ + --html=report.html --self-contained-html \ + --cov=xtesting --cov-reset --cov-report html \ + xtesting/tests/unit [testenv:docs] -basepython = python3.9 +basepython = python3.10 commands = doc8 README.rst api --ignore-path api/build sphinx-build -W -b html api/ api/build [testenv:pep8] -basepython = python3.9 +basepython = python3.10 commands = flake8 [testenv:pylint] -basepython = python3.9 +basepython = python3.10 whitelist_externals = bash commands = pylint --min-similarity-lines=10 \ --disable=locally-disabled --ignore-imports=y --reports=n --extension-pkg-whitelist=lxml xtesting [testenv:yamllint] -basepython = python3.9 +basepython = python3.10 files = .travis.yml ansible @@ -45,33 +44,28 @@ files = commands = yamllint -s {[testenv:yamllint]files} -[testenv:py38] -commands = nosetests xtesting/tests/unit - [testenv:bashate] -basepython = python3.9 +basepython = python3.10 files = build.sh commands = bashate {[testenv:bashate]files} [testenv:bandit] -basepython = python3.9 +basepython = python3.10 commands = bandit -r xtesting -x tests -n 5 -ll -s B602 [testenv:cover] -basepython = python3.9 +basepython = python3.10 dirs = xtesting/tests/unit/ci xtesting/tests/unit/core xtesting/tests/unit/utils/test_decorators.py -commands = nosetests --with-coverage --cover-tests \ - --cover-package xtesting.core \ - --cover-package xtesting.tests.unit \ - --cover-package xtesting.utils.decorators \ - --cover-min-percentage 100 {[testenv:cover]dirs} +commands = + pytest --cov=xtesting --cov-reset --cov-report html --cov-fail-under=100 \ + {[testenv:cover]dirs} [testenv:perm] -basepython = python3.9 +basepython = python3.10 whitelist_externals = bash path=. -not -path './.tox/*' -not -path './.git/*' -not -path './doc/reveal.js/*' commands = -- cgit 1.2.3-korg