diff options
| author | Tim Golden <mail@timgolden.me.uk> | 2018-07-28 18:27:11 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-07-28 18:27:11 +0100 |
| commit | 1561703a78849ac3511055590d9d1bd2c62a2072 (patch) | |
| tree | 3f340e73019b01d61e35f9040cb2b6572535b092 /Lib/test/test_bz2.py | |
| parent | c6dabe37e3c4d449562182b044184d1756bea037 (diff) | |
| download | cpython-git-1561703a78849ac3511055590d9d1bd2c62a2072.tar.gz | |
bpo-42349: Switch to test.support.unlink per review by Serhiy Storchaka (GH-8529)
Serhiy Storchaka pointed out that using test.support.unlink was preferable
Diffstat (limited to 'Lib/test/test_bz2.py')
| -rw-r--r-- | Lib/test/test_bz2.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/Lib/test/test_bz2.py b/Lib/test/test_bz2.py index e62729a5a2..f158b901b9 100644 --- a/Lib/test/test_bz2.py +++ b/Lib/test/test_bz2.py @@ -81,10 +81,7 @@ class BaseTest(unittest.TestCase): os.close(fd) def tearDown(self): - try: - os.unlink(self.filename) - except FileNotFoundError: - pass + unlink(self.filename) class BZ2FileTest(BaseTest): |
