summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/conftest.py7
-rw-r--r--tests/test_bdist_wheel.py2
2 files changed, 8 insertions, 1 deletions
diff --git a/tests/conftest.py b/tests/conftest.py
index 1b8aa99..eb85272 100644
--- a/tests/conftest.py
+++ b/tests/conftest.py
@@ -12,7 +12,12 @@ import pytest
@pytest.fixture(scope='session')
def wheels_and_eggs(tmpdir_factory):
"""Build wheels and eggs from test distributions."""
- test_distributions = "complex-dist", "simple.dist", "headers.dist", "unicode.dist"
+ test_distributions = "complex-dist", "simple.dist", "headers.dist"
+ if sys.version_info >= (3, 6):
+ # Only Python 3.6+ can handle packaging unicode file names reliably
+ # across different platforms
+ test_distributions += ("unicode.dist",)
+
pwd = os.path.abspath(os.curdir)
this_dir = os.path.dirname(__file__)
build_dir = tmpdir_factory.mktemp('build')
diff --git a/tests/test_bdist_wheel.py b/tests/test_bdist_wheel.py
index 40ce37f..729a6a2 100644
--- a/tests/test_bdist_wheel.py
+++ b/tests/test_bdist_wheel.py
@@ -45,6 +45,8 @@ def test_no_scripts(wheel_paths):
assert '.data/scripts/' not in entry.filename
+@pytest.mark.skipif(sys.version_info < (3, 6),
+ reason='Packaging unicode file names only works reliably on Python 3.6+')
def test_unicode_record(wheel_paths):
path = next(path for path in wheel_paths if 'unicode.dist' in path)
with ZipFile(path) as zf: