Skip to content

Commit

Permalink
Refactor TestRegressions to use symlink_or_skip_test
Browse files Browse the repository at this point in the history
  • Loading branch information
abravalheri committed Aug 15, 2023
1 parent 3463e0f commit 5c453aa
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions setuptools/tests/test_sdist.py
Original file line number Diff line number Diff line change
Expand Up @@ -849,11 +849,7 @@ def test_symlink_in_extension_depends(self, monkeypatch, tmp_path, dep_path):
# Given a project with a symlinked dir and a "depends" targeting that dir
files = self.files_for_symlink_in_extension_depends(tmp_path, dep_path)
jaraco.path.build(files, prefix=str(tmp_path))

try:
os.symlink(tmp_path / "external", tmp_path / "project/myheaders")
except (OSError, NotImplementedError):
pytest.skip("symlink not supported in OS")
symlink_or_skip_test(tmp_path / "external", tmp_path / "project/myheaders")

# When `sdist` runs, there should be no error
members = run_sdist(monkeypatch, tmp_path / "project")
Expand Down

0 comments on commit 5c453aa

Please sign in to comment.