aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/tests/test_easy_install.py
diff options
context:
space:
mode:
authorOfek Lev <ofekmeister@gmail.com>2020-06-14 14:21:26 -0400
committerOfek Lev <ofekmeister@gmail.com>2020-06-14 14:21:26 -0400
commitd6501f3c75384340f1742a864c1ffa76977437b6 (patch)
tree56a750c13be0d4e49e3e7842f240e980b8507714 /setuptools/tests/test_easy_install.py
parent01121d057bea0128c34a92813c51ba3ec4902fce (diff)
downloadexternal_python_setuptools-d6501f3c75384340f1742a864c1ffa76977437b6.tar.gz
external_python_setuptools-d6501f3c75384340f1742a864c1ffa76977437b6.tar.bz2
external_python_setuptools-d6501f3c75384340f1742a864c1ffa76977437b6.zip
address
Diffstat (limited to 'setuptools/tests/test_easy_install.py')
-rw-r--r--setuptools/tests/test_easy_install.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/setuptools/tests/test_easy_install.py b/setuptools/tests/test_easy_install.py
index 58108db6..9aa2bd63 100644
--- a/setuptools/tests/test_easy_install.py
+++ b/setuptools/tests/test_easy_install.py
@@ -71,9 +71,7 @@ class TestEasyInstallTest:
def test_get_script_args(self):
header = ei.CommandSpec.best().from_environment().as_header()
- try:
- from importlib.metadata import distribution # noqa: F401
-
+ if sys.version_info >= (3, 8):
expected = header + DALS(r"""
# EASY-INSTALL-ENTRY-SCRIPT: 'spec','console_scripts','name'
__requires__ = 'spec'
@@ -87,7 +85,7 @@ class TestEasyInstallTest:
if entry_point.group == 'console_scripts' and entry_point.name == 'name':
sys.exit(entry_point.load()())
""") # noqa: E501
- except ImportError:
+ else:
expected = header + DALS(r"""
# EASY-INSTALL-ENTRY-SCRIPT: 'spec','console_scripts','name'
__requires__ = 'spec'