[TIP] Resetting or Restarting coverage.py trace
shai at sealights.io
Sat Oct 15 23:36:42 PDT 2016
So I'm using coverage.py API
cov = coverage.Coverage()cov.start()
# .. call your code ..
The main thread creates a coverage instance and starts it.
During the lifetime of the program I have multiple threads and I need every
once in while to reset or restart the coverage process (or clear coverage
data) from one of the underlying threads.
Problem is that tracing is stopped after I do that. I guess it's because I
start it from another thread.
Is there a way I can reset/restart coverage from another thread or manually
clear coverage data?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the testing-in-python