[Python-checkins] closes bpo-34661: Fix test_shutil if unzip doesn't support -t. (GH-9262)
Benjamin Peterson
webhook-mailer at python.org
Thu Sep 13 13:08:49 EDT 2018
https://github.com/python/cpython/commit/a710ebd21b09efe902dde84d4862ce5c6427f7af
commit: a710ebd21b09efe902dde84d4862ce5c6427f7af
branch: master
author: Benjamin Peterson <benjamin at python.org>
committer: GitHub <noreply at github.com>
date: 2018-09-13T10:08:46-07:00
summary:
closes bpo-34661: Fix test_shutil if unzip doesn't support -t. (GH-9262)
files:
A Misc/NEWS.d/next/Tests/2018-09-13-09-53-15.bpo-34661.bdTamP.rst
M Lib/test/test_shutil.py
diff --git a/Lib/test/test_shutil.py b/Lib/test/test_shutil.py
index 7e0a3292e0f8..797228db4d51 100644
--- a/Lib/test/test_shutil.py
+++ b/Lib/test/test_shutil.py
@@ -1181,6 +1181,8 @@ def test_unzip_zipfile(self):
subprocess.check_output(zip_cmd, stderr=subprocess.STDOUT)
except subprocess.CalledProcessError as exc:
details = exc.output.decode(errors="replace")
+ if 'unrecognized option: t' in details:
+ self.skip("unzip doesn't support -t")
msg = "{}\n\n**Unzip Output**\n{}"
self.fail(msg.format(exc, details))
diff --git a/Misc/NEWS.d/next/Tests/2018-09-13-09-53-15.bpo-34661.bdTamP.rst b/Misc/NEWS.d/next/Tests/2018-09-13-09-53-15.bpo-34661.bdTamP.rst
new file mode 100644
index 000000000000..fc2b8e90ead5
--- /dev/null
+++ b/Misc/NEWS.d/next/Tests/2018-09-13-09-53-15.bpo-34661.bdTamP.rst
@@ -0,0 +1 @@
+Fix test_shutil if unzip doesn't support -t.
More information about the Python-checkins
mailing list