File tree Expand file tree Collapse file tree 1 file changed +2
-16
lines changed Expand file tree Collapse file tree 1 file changed +2
-16
lines changed Original file line number Diff line number Diff line change @@ -6,19 +6,5 @@ Getting coverage on pytest plugins is a very particular situation. Because of ho
6
6
entrypoints) it doesn't allow controlling the order in which the plugins load.
7
7
See `pytest/issues/935 <https://github.com/pytest-dev/pytest/issues/935#issuecomment-245107960 >`_ for technical details.
8
8
9
- The current way of dealing with this problem is using the append feature and manually starting ``pytest-cov ``'s engine, eg::
10
-
11
- COV_CORE_SOURCE=src COV_CORE_CONFIG=.coveragerc COV_CORE_DATAFILE=.coverage.eager pytest --cov=src --cov-append
12
-
13
- Alternatively you can have this in ``tox.ini `` (if you're using `Tox <https://tox.wiki/en/latest/ >`_ of course)::
14
-
15
- [testenv]
16
- setenv =
17
- COV_CORE_SOURCE=
18
- COV_CORE_CONFIG={toxinidir}/.coveragerc
19
- COV_CORE_DATAFILE={toxinidir}/.coverage
20
-
21
- And in ``pytest.ini `` / ``tox.ini `` / ``setup.cfg ``::
22
-
23
- [tool:pytest]
24
- addopts = --cov --cov-append
9
+ **Currently there is no way to measure your pytest plugin if you use pytest-cov **.
10
+ You should change your test invocations to use ``coverage run -m pytest ... `` instead.
You can’t perform that action at this time.
0 commit comments