diff options
-rw-r--r-- | tests/test_cmdline.py | 1 | ||||
-rw-r--r-- | tests/test_html.py | 2 | ||||
-rw-r--r-- | tests/test_process.py | 6 |
3 files changed, 4 insertions, 5 deletions
diff --git a/tests/test_cmdline.py b/tests/test_cmdline.py index 58a2d84a..775e0033 100644 --- a/tests/test_cmdline.py +++ b/tests/test_cmdline.py @@ -635,6 +635,7 @@ class CmdMainTest(CoverageTest): self.addCleanup(self.restore_coverage_script) def restore_coverage_script(self): + """A cleanup""" coverage.cmdline.CoverageScript = self.old_CoverageScript def test_normal(self): diff --git a/tests/test_html.py b/tests/test_html.py index 31b4d876..6b398c43 100644 --- a/tests/test_html.py +++ b/tests/test_html.py @@ -66,6 +66,7 @@ class HtmlDeltaTest(HtmlTestHelpers, CoverageTest): self.addCleanup(self.restore_coverage_version) def restore_coverage_version(self): + """A cleanup.""" coverage.__version__ = self.real_coverage_version def test_html_created(self): @@ -362,6 +363,7 @@ class HtmlStaticFileTest(CoverageTest): self.addCleanup(self.restore_static_path) def restore_static_path(self): + """A cleanup.""" coverage.html.STATIC_PATH = self.original_path def test_copying_static_files_from_system(self): diff --git a/tests/test_process.py b/tests/test_process.py index 4f612748..1ae8e922 100644 --- a/tests/test_process.py +++ b/tests/test_process.py @@ -738,11 +738,7 @@ class ProcessCoverageMixin(object): else: # pragma: not covered raise Exception("Couldn't find a place for the .pth file") - self.addCleanup(self.remove_pth_path) - - def remove_pth_path(self): - # Clean up the .pth file we made. - os.remove(self.pth_path) + self.addCleanup(os.remove, self.pth_path) class ProcessStartupTest(ProcessCoverageMixin, CoverageTest): |