From b1b065680568a711614e7c0d81ba72637c89b260 Mon Sep 17 00:00:00 2001 From: Christian Heimes Date: Tue, 21 Jun 2022 21:25:39 +0200 Subject: [PATCH] [3.11] gh-91387: Fix tarfile test on WASI (GH-93984) (#94074) Co-authored-by: Christian Heimes --- Lib/test/test_tarfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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('/'))) -- 2.47.3