blob: de94da54798ce38ec32a421b46b5833475dc58b0 [file] [log] [blame]
Fred Drakebb7c1442004-06-15 15:49:46 +00001"""Tests for distutils.
2
3The tests for distutils are defined in the distutils.tests package;
4the test_suite() function there returns a test suite that's ready to
5be run.
6"""
7
Victor Stinner69ca32e2021-04-16 11:26:40 +02008import warnings
9from test import support
10from test.support import warnings_helper
11
12with warnings_helper.check_warnings(
13 ("The distutils package is deprecated", DeprecationWarning)):
14
15 import distutils.tests
Fred Drakebb7c1442004-06-15 15:49:46 +000016
17
18def test_main():
Toshio Kuratomi997443c2020-01-27 04:08:39 -080019 # used by regrtest
Victor Stinner69ca32e2021-04-16 11:26:40 +020020 support.run_unittest(distutils.tests.test_suite())
21 support.reap_children()
Fred Drakebb7c1442004-06-15 15:49:46 +000022
23
Toshio Kuratomi997443c2020-01-27 04:08:39 -080024def load_tests(*_):
25 # used by unittest
26 return distutils.tests.test_suite()
27
28
Fred Drakebb7c1442004-06-15 15:49:46 +000029if __name__ == "__main__":
30 test_main()