Skip to content

Commit dc3b890

Browse files
committed
fix combined coverage report
1 parent 69b774f commit dc3b890

File tree

2 files changed

+22
-44
lines changed

2 files changed

+22
-44
lines changed

.meta.toml

Lines changed: 16 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# https://github.com/zopefoundation/meta/tree/master/config/pure-python
33
[meta]
44
template = "pure-python"
5-
commit-id = "b5df3766ff8923477f3d24729b19504f0c401a2e"
5+
commit-id = "54e37f7de7149c0d4003e40bbe300d012a851ce7"
66

77
[python]
88
with-pypy = false
@@ -16,7 +16,6 @@ with-future-python = true
1616
use-flake8 = true
1717
additional-envlist = [
1818
"py39-datetime",
19-
"combined-coverage",
2019
]
2120
testenv-deps = [
2221
"datetime: DateTime",
@@ -31,33 +30,27 @@ testenv-commands = [
3130
"pip list",
3231
"pytest --cov=src --cov=tests --cov-report= {posargs}",
3332
]
34-
testenv-additional = [
35-
"",
36-
"[testenv:combined-coverage]",
37-
"basepython = python3",
38-
"allowlist_externals =",
39-
" mkdir",
40-
"deps =",
41-
" coverage",
42-
" -cconstraints.txt",
43-
"setenv =",
44-
" COVERAGE_FILE=.coverage",
45-
"commands =",
46-
" mkdir -p {toxinidir}/parts/htmlcov",
47-
" coverage erase",
48-
" coverage combine",
49-
" coverage html",
50-
" coverage report -m --fail-under=100",
51-
"depends = py36,py37,py38,py39,py39-datetime,py310,py311,coverage",
33+
coverage-basepython = "python3"
34+
coverage-deps = [
35+
"coverage",
36+
"-cconstraints.txt",
37+
]
38+
coverage-command = [
39+
"mkdir -p {toxinidir}/parts/htmlcov",
40+
"coverage combine",
41+
"coverage html",
42+
"coverage report -m --fail-under=100",
5243
]
53-
coverage-basepython = "python3.8"
54-
coverage-command = "pytest --cov=src --cov=tests --cov-report= {posargs}"
44+
coverage-depends = "py36,py37,py38,py39,py39-datetime,py310,py311"
5545
coverage-setenv = [
5646
"COVERAGE_FILE=.coverage",
5747
]
48+
coverage-allowlist_externals = [
49+
"mkdir",
50+
]
5851

5952
[coverage]
60-
fail-under = 98.8
53+
fail-under = 100.0
6154

6255
[isort]
6356
additional-sources = "{toxinidir}/tests"

tox.ini

Lines changed: 6 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ envlist =
1313
docs
1414
coverage
1515
py39-datetime
16-
combined-coverage
1716

1817
[testenv]
1918
usedevelop = true
@@ -34,23 +33,6 @@ extras =
3433
test
3534
docs
3635

37-
[testenv:combined-coverage]
38-
basepython = python3
39-
allowlist_externals =
40-
mkdir
41-
deps =
42-
coverage
43-
-cconstraints.txt
44-
setenv =
45-
COVERAGE_FILE=.coverage
46-
commands =
47-
mkdir -p {toxinidir}/parts/htmlcov
48-
coverage erase
49-
coverage combine
50-
coverage html
51-
coverage report -m --fail-under=100
52-
depends = py36,py37,py38,py39,py39-datetime,py310,py311,coverage
53-
5436
[testenv:lint]
5537
basepython = python3
5638
skip_install = true
@@ -83,7 +65,7 @@ commands =
8365
sphinx-build -b doctest -d docs/_build/doctrees docs docs/_build/doctest
8466

8567
[testenv:coverage]
86-
basepython = python3.8
68+
basepython = python3
8769
allowlist_externals =
8870
mkdir
8971
deps =
@@ -96,10 +78,13 @@ setenv =
9678
COVERAGE_FILE=.coverage
9779
commands =
9880
mkdir -p {toxinidir}/parts/htmlcov
99-
pytest --cov=src --cov=tests --cov-report= {posargs}
81+
mkdir -p {toxinidir}/parts/htmlcov
82+
coverage combine
83+
coverage html
84+
coverage report -m --fail-under=100
10085
coverage run -a -m sphinx -b doctest -d {envdir}/.cache/doctrees docs {envdir}/.cache/doctest
10186
coverage html
102-
coverage report -m --fail-under=98.8
87+
coverage report -m --fail-under=100.0
10388

10489
[coverage:run]
10590
branch = True

0 commit comments

Comments
 (0)