summaryrefslogtreecommitdiff
path: root/setuptools/tests/test_build_meta.py
diff options
context:
space:
mode:
Diffstat (limited to 'setuptools/tests/test_build_meta.py')
-rw-r--r--setuptools/tests/test_build_meta.py31
1 files changed, 30 insertions, 1 deletions
diff --git a/setuptools/tests/test_build_meta.py b/setuptools/tests/test_build_meta.py
index 8fcf3055..fdb4b950 100644
--- a/setuptools/tests/test_build_meta.py
+++ b/setuptools/tests/test_build_meta.py
@@ -380,7 +380,7 @@ class TestBuildMetaBackend:
setup(
name="qux",
version="0.0.0",
- py_modules=["hello.py"],
+ py_modules=["hello"],
setup_requires={setup_literal},
)
""").format(setup_literal=setup_literal),
@@ -407,6 +407,35 @@ class TestBuildMetaBackend:
assert expected == sorted(actual)
+ def test_dont_install_setup_requires(self, tmpdir_cwd):
+ files = {
+ 'setup.py': DALS("""
+ from setuptools import setup
+
+ setup(
+ name="qux",
+ version="0.0.0",
+ py_modules=["hello"],
+ setup_requires=["does-not-exist >99"],
+ )
+ """),
+ 'hello.py': DALS("""
+ def run():
+ print('hello')
+ """),
+ }
+
+ build_files(files)
+
+ build_backend = self.get_build_backend()
+
+ dist_dir = os.path.abspath('pip-dist-info')
+ os.makedirs(dist_dir)
+
+ # does-not-exist can't be satisfied, so if it attempts to install
+ # setup_requires, it will fail.
+ build_backend.prepare_metadata_for_build_wheel(dist_dir)
+
_sys_argv_0_passthrough = {
'setup.py': DALS("""
import os