Commit 77aefc12 authored by Jason R. Coombs's avatar Jason R. Coombs

Restore test_build_sdist_relative_path_import to its former simple implementation.

parent daf01571
......@@ -125,8 +125,8 @@ defns = [
class TestBuildMetaBackend:
backend_name = 'setuptools.build_meta'
def get_build_backend(self, **kwargs):
return BuildBackend(backend_name=self.backend_name, **kwargs)
def get_build_backend(self):
return BuildBackend(backend_name=self.backend_name)
@pytest.fixture(params=defns)
def build_backend(self, tmpdir, request):
......@@ -334,11 +334,11 @@ class TestBuildMetaBackend:
""")
}
def test_build_sdist_relative_path_import(self, tmp_path):
build_files(self._relative_path_import_files, prefix=str(tmp_path))
build_backend = self.get_build_backend(cwd=tmp_path)
def test_build_sdist_relative_path_import(self, tmpdir_cwd):
build_files(self._relative_path_import_files)
build_backend = self.get_build_backend()
with pytest.raises(ImportError, match="^No module named 'hello'$"):
build_backend.build_sdist(tmp_path / "temp")
build_backend.build_sdist("temp")
@pytest.mark.parametrize('setup_literal, requirements', [
("'foo'", ['foo']),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment