Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions test/test_query.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,15 @@


class Tests(unittest.TestCase):
"""Test querying tools from several modules.

Note:

Tests that run setup script directly fail due to conflict between distutils used internally
by setuptools and distutils used internally by pip. For more information, see:
- https://github.com/pypa/setuptools/issues/3297
- https://github.com/pypa/pip/issues/8761
"""

def _check_examples_count(self, description, examples):
lvl = logging.WARNING if len(examples) < 10 else logging.INFO
Expand Down Expand Up @@ -87,6 +96,7 @@ def test_query_pkg_info(self):

@unittest.skipUnless(
os.environ.get('TEST_PACKAGING') or os.environ.get('CI'), 'skipping packaging test')
@unittest.skipIf(sys.version_info < (3, 12), 'requires Python 3.12+')
def test_query_pkg_info_current(self):
with preserve_logger_level('version_query'):
run_module('setup', 'build')
Expand Down Expand Up @@ -120,6 +130,7 @@ def test_query_package_folder(self):

@unittest.skipUnless(
os.environ.get('TEST_PACKAGING') or os.environ.get('CI'), 'skipping packaging test')
@unittest.skipIf(sys.version_info < (3, 12), 'requires Python 3.12+')
def test_query_package_folder_current(self):
with preserve_logger_level('version_query'):
run_module('setup', 'build')
Expand Down
Loading