diff -r 1a1661750890 Lib/test/test_asyncio/__init__.py --- a/Lib/test/test_asyncio/__init__.py Mon Feb 17 23:12:37 2014 -0500 +++ b/Lib/test/test_asyncio/__init__.py Tue Feb 18 12:44:11 2014 +0800 @@ -10,20 +10,18 @@ def suite(): - tests_file = os.path.join(os.path.dirname(__file__), 'tests.txt') - with open(tests_file) as fp: - test_names = fp.read().splitlines() tests = unittest.TestSuite() loader = unittest.TestLoader() - for test_name in test_names: - mod_name = 'test.' + test_name - try: - __import__(mod_name) - except unittest.SkipTest: - pass - else: - mod = sys.modules[mod_name] - tests.addTests(loader.loadTestsFromModule(mod)) + for fn in os.listdir(os.path.dirname(__file__)): + if fn.startswith("test") and fn.endswith(".py"): + mod_name = 'test.test_asyncio.' + fn[:-3] + try: + __import__(mod_name) + except unittest.SkipTest: + pass + else: + mod = sys.modules[mod_name] + tests.addTests(loader.loadTestsFromModule(mod)) return tests diff -r 1a1661750890 Lib/test/test_asyncio/tests.txt --- a/Lib/test/test_asyncio/tests.txt Mon Feb 17 23:12:37 2014 -0500 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,14 +0,0 @@ -test_asyncio.test_base_events -test_asyncio.test_events -test_asyncio.test_futures -test_asyncio.test_locks -test_asyncio.test_proactor_events -test_asyncio.test_queues -test_asyncio.test_selector_events -test_asyncio.test_streams -test_asyncio.test_subprocess -test_asyncio.test_tasks -test_asyncio.test_transports -test_asyncio.test_unix_events -test_asyncio.test_windows_events -test_asyncio.test_windows_utils