Skip to content

Commit

Permalink
Move comment nearer the skip directive. Update wording.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Apr 12, 2024
1 parent 6b6633a commit 5598256
Showing 1 changed file with 13 additions and 14 deletions.
27 changes: 13 additions & 14 deletions distutils/tests/test_sysconfig.py
Expand Up @@ -202,22 +202,21 @@ def test_sysconfig_module(self):
'LDFLAGS'
)

# On macOS, binary installers support extension module building on
# various levels of the operating system with differing Xcode
# configurations, requiring customization of some of the
# compiler configuration directives to suit the environment on
# the installed machine. Some of these customizations may require
# running external programs and are thus deferred until needed by
# the first extension module build. Only
# the Distutils version of sysconfig is used for extension module
# builds, which happens earlier in the Distutils tests. This may
# cause the following tests to fail since no tests have caused
# the global version of sysconfig to call the customization yet.
# The solution for now is to simply skip this test in this case.
# The longer-term solution is to only have one version of sysconfig.
@pytest.mark.skipif("sysconfig.get_config_var('CUSTOMIZED_OSX_COMPILER')")
def test_sysconfig_compiler_vars(self):
# On OS X, binary installers support extension module building on
# various levels of the operating system with differing Xcode
# configurations. This requires customization of some of the
# compiler configuration directives to suit the environment on
# the installed machine. Some of these customizations may require
# running external programs and, so, are deferred until needed by
# the first extension module build. With Python 3.3, only
# the Distutils version of sysconfig is used for extension module
# builds, which happens earlier in the Distutils tests. This may
# cause the following tests to fail since no tests have caused
# the global version of sysconfig to call the customization yet.
# The solution for now is to simply skip this test in this case.
# The longer-term solution is to only have one version of sysconfig.

import sysconfig as global_sysconfig

if sysconfig.get_config_var('CUSTOMIZED_OSX_COMPILER'):
Expand Down

0 comments on commit 5598256

Please sign in to comment.