Fred Drake | bb7c144 | 2004-06-15 15:49:46 +0000 | [diff] [blame] | 1 | """Tests for distutils. |
| 2 | |
| 3 | The tests for distutils are defined in the distutils.tests package; |
| 4 | the test_suite() function there returns a test suite that's ready to |
| 5 | be run. |
| 6 | """ |
| 7 | |
Victor Stinner | 69ca32e | 2021-04-16 11:26:40 +0200 | [diff] [blame] | 8 | import warnings |
| 9 | from test import support |
| 10 | from test.support import warnings_helper |
| 11 | |
| 12 | with warnings_helper.check_warnings( |
Steve Dower | c1a9535 | 2021-04-28 16:21:55 +0100 | [diff] [blame] | 13 | ("The distutils package is deprecated", DeprecationWarning), quiet=True): |
Victor Stinner | 69ca32e | 2021-04-16 11:26:40 +0200 | [diff] [blame] | 14 | |
| 15 | import distutils.tests |
Fred Drake | bb7c144 | 2004-06-15 15:49:46 +0000 | [diff] [blame] | 16 | |
| 17 | |
Toshio Kuratomi | 997443c | 2020-01-27 04:08:39 -0800 | [diff] [blame] | 18 | def load_tests(*_): |
| 19 | # used by unittest |
| 20 | return distutils.tests.test_suite() |
| 21 | |
| 22 | |
Serhiy Storchaka | bedce35 | 2021-09-19 22:36:03 +0300 | [diff] [blame] | 23 | def tearDownModule(): |
| 24 | support.reap_children() |
| 25 | |
| 26 | |
Fred Drake | bb7c144 | 2004-06-15 15:49:46 +0000 | [diff] [blame] | 27 | if __name__ == "__main__": |
Serhiy Storchaka | bedce35 | 2021-09-19 22:36:03 +0300 | [diff] [blame] | 28 | unittest.main() |