summaryrefslogtreecommitdiff
path: root/setuptools/tests/test_sdist.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2022-11-13 14:07:08 -0500
committerJason R. Coombs <jaraco@jaraco.com>2022-11-13 14:07:08 -0500
commita0e8e53cecc238e3bce2247308fe7dd94114ef35 (patch)
treebf8e5761259f2e4ebc7cd7a30195121421984aa6 /setuptools/tests/test_sdist.py
parent515c0ae334c30d03bccf2670fd2a56e8ab85945d (diff)
downloadpython-setuptools-git-a0e8e53cecc238e3bce2247308fe7dd94114ef35.tar.gz
Skip an additional test under xdist. Ref pypa/distutils#183. Expanded workaround for pytest-dev/pytest-xdist#843.
Diffstat (limited to 'setuptools/tests/test_sdist.py')
-rw-r--r--setuptools/tests/test_sdist.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/setuptools/tests/test_sdist.py b/setuptools/tests/test_sdist.py
index adf4325d..30631c24 100644
--- a/setuptools/tests/test_sdist.py
+++ b/setuptools/tests/test_sdist.py
@@ -89,6 +89,12 @@ fail_on_latin1_encoded_filenames = pytest.mark.xfail(
)
+skip_under_xdist = pytest.mark.skipif(
+ "os.environ.get('PYTEST_XDIST_WORKER')",
+ reason="pytest-dev/pytest-xdist#843",
+)
+
+
def touch(path):
path.write_text('', encoding='utf-8')
@@ -322,10 +328,7 @@ class TestSdistTest:
# The filelist should have been updated as well
assert u_filename in mm.filelist.files
- @pytest.mark.skipif(
- "os.environ.get('PYTEST_XDIST_WORKER')",
- reason="pytest-dev/pytest-xdist#843",
- )
+ @skip_under_xdist
def test_write_manifest_skips_non_utf8_filenames(self):
"""
Files that cannot be encoded to UTF-8 (specifically, those that
@@ -464,6 +467,7 @@ class TestSdistTest:
return str(item)
@fail_on_latin1_encoded_filenames
+ @skip_under_xdist
def test_sdist_with_latin1_encoded_filename(self):
# Test for #303.
dist = Distribution(self.make_strings(SETUP_ATTRS))