diff options
author | Steve Dower <steve.dower@microsoft.com> | 2021-07-12 16:31:12 +0100 |
---|---|---|
committer | Steve Dower <steve.dower@microsoft.com> | 2021-07-12 16:31:12 +0100 |
commit | 902f0a9b1d4eb39279b237da3950338e8bf20bfe (patch) | |
tree | c93d93a117b2a2f48d20e7cfbbd7e89e4b66404e | |
parent | 1eb36f2c1ee3bc42aa386291518bf62a97276155 (diff) | |
download | python-setuptools-git-902f0a9b1d4eb39279b237da3950338e8bf20bfe.tar.gz |
Override PyPy case in test
-rw-r--r-- | setuptools/tests/test_build_ext.py | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/setuptools/tests/test_build_ext.py b/setuptools/tests/test_build_ext.py index 5286358e..0248c5aa 100644 --- a/setuptools/tests/test_build_ext.py +++ b/setuptools/tests/test_build_ext.py @@ -13,6 +13,9 @@ from . import environment from .textwrap import DALS +IS_PYPY = '__pypy__' in sys.builtin_module_names + + class TestBuildExt: def test_get_ext_filename(self): """ @@ -63,7 +66,14 @@ class TestBuildExt: ) # Mock value needed to pass tests ext._links_to_dynamic = False - expect = cmd.get_ext_filename('for_abi3') + + if not IS_PYPY: + expect = cmd.get_ext_filename('for_abi3') + else: + # PyPy builds do not use ABI3 tag, so they will + # also get the overridden suffix. + expect = 'for_abi3.test_suffix' + try: os.environ['SETUPTOOLS_EXT_SUFFIX'] = '.test-suffix' res = cmd.get_ext_filename('normal') |