From 7390942aa16be9b894c31563ec9f2b502ed28338 Mon Sep 17 00:00:00 2001 From: "Michael W. Hudson" Date: Mon, 20 Jun 2005 13:45:34 +0000 Subject: [PATCH] test_asynchat is no longer expected to produce output. also, wait for threads to finish before proceeding. --- Lib/test/output/test_asynchat | 3 --- Lib/test/test_asynchat.py | 4 +++- 2 files changed, 3 insertions(+), 4 deletions(-) delete mode 100644 Lib/test/output/test_asynchat diff --git a/Lib/test/output/test_asynchat b/Lib/test/output/test_asynchat deleted file mode 100644 index e2e67f3f959..00000000000 --- a/Lib/test/output/test_asynchat +++ /dev/null @@ -1,3 +0,0 @@ -test_asynchat -Connected -Received: 'hello world' diff --git a/Lib/test/test_asynchat.py b/Lib/test/test_asynchat.py index d10e389a55c..f93587acbef 100644 --- a/Lib/test/test_asynchat.py +++ b/Lib/test/test_asynchat.py @@ -6,7 +6,7 @@ import unittest from test import test_support HOST = "127.0.0.1" -PORT = 54321 +PORT = 54322 class echo_server(threading.Thread): @@ -67,6 +67,7 @@ class TestAsynchat(unittest.TestCase): c.push("hello ") c.push("world\n") asyncore.loop() + s.join() self.assertEqual(c.contents, 'hello world') @@ -79,6 +80,7 @@ class TestAsynchat(unittest.TestCase): c.push("hello ") c.push("world\n") asyncore.loop() + s.join() self.assertEqual(c.contents, 'hello ')