test_directory(): Remove the leftover temp directory that's making
the Windows buildbots fail test_tarfile.
diff --git a/Lib/test/test_tarfile.py b/Lib/test/test_tarfile.py
index 0f3df7f..503de26 100644
--- a/Lib/test/test_tarfile.py
+++ b/Lib/test/test_tarfile.py
@@ -295,6 +295,10 @@
def test_directory(self):
path = os.path.join(self.tmpdir, "directory")
+ if os.path.exists(path):
+ # This shouldn't be necessary, but is <wink> if a previous
+ # run was killed in mid-stream.
+ shutil.rmtree(path)
os.mkdir(path)
tarinfo = self.dst.gettarinfo(path)
self.assertEqual(tarinfo.size, 0)