diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2020-09-04 10:22:54 -0400 |
---|---|---|
committer | Jason R. Coombs <jaraco@jaraco.com> | 2020-09-04 10:22:54 -0400 |
commit | fc4d9828768ceebd2f9337481450c88376c013e9 (patch) | |
tree | 6dff622c50739ca19fdfbecf1008a42589d37b57 /conftest.py | |
parent | 7bb73a477de24069002516eb6eb1d755bed9d65b (diff) | |
parent | 03d36b9edb53e266a0b4b836e1e3178f989a0781 (diff) | |
download | python-setuptools-git-feature/implicit-bootstrap.tar.gz |
Merge branch 'master' into feature/implicit-bootstrapfeature/implicit-bootstrap
Diffstat (limited to 'conftest.py')
-rw-r--r-- | conftest.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/conftest.py b/conftest.py index 1746bfb5..25537f56 100644 --- a/conftest.py +++ b/conftest.py @@ -14,9 +14,29 @@ def pytest_addoption(parser): collect_ignore = [ 'tests/manual_test.py', 'setuptools/tests/mod_with_constant.py', + 'setuptools/_distutils', + '_distutils_hack', ] +def pytest_configure(config): + disable_coverage_on_pypy(config) + + +def disable_coverage_on_pypy(config): + """ + Coverage makes tests on PyPy unbearably slow, so disable it. + """ + if '__pypy__' not in sys.builtin_module_names: + return + + # Recommended at pytest-dev/pytest-cov#418 + cov = config.pluginmanager.get_plugin('_cov') + cov.options.no_cov = True + if cov.cov_controller: + cov.cov_controller.pause() + + if sys.version_info < (3,): collect_ignore.append('setuptools/lib2to3_ex.py') collect_ignore.append('setuptools/_imp.py') |