cpython/Lib/test/test_distutils.py
Serhiy Storchaka 14167031eb
[3.11] gh-111309: Use unittest to collect and run distutils tests (GH-111311)
* use unittest.main() instead of run_unittest(test_suite()) to run tests from
  modules via the CLI
* add explicit load_tests() to load doctests
* use test.support.load_package_tests() to load tests in submodules of
  distutils.tests
* removes no longer needed test_suite() functions
2023-10-25 14:57:17 +03:00

22 lines
549 B
Python

"""Tests for distutils.
The tests for distutils are defined in the distutils.tests package.
"""
import unittest
from test import support
from test.support import warnings_helper
with warnings_helper.check_warnings(
("The distutils package is deprecated", DeprecationWarning), quiet=True):
from distutils.tests import load_tests
def tearDownModule():
support.reap_children()
if support.check_sanitizer(address=True):
raise unittest.SkipTest("Exposes ASAN flakiness in GitHub CI")
if __name__ == "__main__":
unittest.main()