From: Christian Heimes Date: Tue, 21 Jun 2022 19:25:39 +0000 (+0200) Subject: [3.11] gh-91387: Fix tarfile test on WASI (GH-93984) (#94074) X-Git-Tag: v3.11.0b4~123 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b1b065680568a711614e7c0d81ba72637c89b260;p=thirdparty%2FPython%2Fcpython.git [3.11] gh-91387: Fix tarfile test on WASI (GH-93984) (#94074) Co-authored-by: Christian Heimes --- diff --git a/Lib/test/test_tarfile.py b/Lib/test/test_tarfile.py index f1aed5ccc6b7..e0389c5dc474 100644 --- a/Lib/test/test_tarfile.py +++ b/Lib/test/test_tarfile.py @@ -1031,7 +1031,7 @@ class LongnameTest: os.mkdir(longdir) tar.add(longdir) finally: - os.rmdir(longdir) + os.rmdir(longdir.rstrip("/")) with tarfile.open(tmpname) as tar: self.assertIsNotNone(tar.getmember(longdir)) self.assertIsNotNone(tar.getmember(longdir.removesuffix('/')))