clean-up CoverageProcess (not used anymore)
This commit is contained in:
@@ -4,20 +4,13 @@ import os
|
||||
|
||||
|
||||
class CoverageProcess(Process):
|
||||
def __init__(self, *args, config_file=None, **kwargs):
|
||||
self._config_file = config_file
|
||||
super().__init__(*args, **kwargs)
|
||||
|
||||
def run(self):
|
||||
if self._config_file:
|
||||
cov = Coverage(config_file=self._config_file, data_suffix=os.getpid(), auto_data=True)
|
||||
cov._warn_no_data = False
|
||||
cov.start()
|
||||
cov = Coverage(config_file=True, data_suffix=os.getpid(), auto_data=True)
|
||||
cov._warn_no_data = False
|
||||
cov.start()
|
||||
|
||||
try:
|
||||
super().run()
|
||||
finally:
|
||||
cov.stop()
|
||||
cov.save()
|
||||
else:
|
||||
try:
|
||||
super().run()
|
||||
finally:
|
||||
cov.stop()
|
||||
cov.save()
|
||||
|
||||
Reference in New Issue
Block a user