There was an error while loading. Please reload this page.
1 parent c91586b commit 8b3dc69Copy full SHA for 8b3dc69
1 file changed
Lib/test/test_logging.py
@@ -6358,11 +6358,12 @@ def setUp(self):
6358
self.rmfiles = []
6359
6360
def tearDown(self):
6361
- for fn in self.rmfiles:
6362
- os.unlink(fn)
6363
- if os.path.exists(self.fn):
6364
- os.unlink(self.fn)
6365
- BaseTest.tearDown(self)
+ try:
+ for fn in self.rmfiles:
+ os_helper.unlink(fn)
+ os_helper.unlink(self.fn)
+ finally:
6366
+ BaseTest.tearDown(self)
6367
6368
def assertLogFile(self, filename):
6369
"Assert a log file is there and register it for deletion"
0 commit comments