Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
CoverageSqliteData.filename gets mutated with suffix #708
This is relevant for when using
This appears to be (one of) the reason(s) for pytest-cov to have a separate Coverage object for this (https://github.com/pytest-dev/pytest-cov/blob/7205428bfb9ab9f8dbcaeefe23ce5fe426bb06b9/src/pytest_cov/engine.py#L152-L155).
Yes, that's correct.
IIRC I've looked into changing pytest-cov with regard to the new API (not really feasible, since coveragepy 4 should be supported of course).
As for pytest-django, where I've noticed and debugged this with I've gone with coveragepy directly now (pytest-dev/pytest-django@c72b10a).
The use case is combining (see pytest-dev/pytest-cov#226 - pytest-cov uses a separate Coverage instance just for having an unmodified
When looking into this I've tried to create
Instead I think
The problem currently is that
Heh, I ask for an example, and you show me my own code! :)
I'd like to write a failing test case for this. It seems like the scenario is: use a Coverage object with parallel=true to run some code, then try to use that same object to combine, and it won't find all the data files? I'm not sure that's a reasonable use case for the API, but help me understand.