diff -r 44ebac378e51 Lib/test/test_ctypes.py --- a/Lib/test/test_ctypes.py Wed Feb 27 10:04:23 2013 -0800 +++ b/Lib/test/test_ctypes.py Wed Feb 27 15:45:18 2013 -0600 @@ -1,16 +1,16 @@ import unittest -from test.support import run_unittest, import_module +from test.support import import_module # Skip tests if _ctypes module was not built. import_module('_ctypes') import ctypes.test -def test_main(): +def load_tests(*args): skipped, testcases = ctypes.test.get_tests(ctypes.test, "test_*.py", verbosity=0) suites = [unittest.makeSuite(t) for t in testcases] - run_unittest(unittest.TestSuite(suites)) + return unittest.TestSuite(suites) if __name__ == "__main__": - test_main() + unittest.main()