mirror of https://github.com/python/cpython
test_asynchat is no longer expected to produce output.
also, wait for threads to finish before proceeding.
This commit is contained in:
parent
7b279078c0
commit
7390942aa1
|
@ -1,3 +0,0 @@
|
|||
test_asynchat
|
||||
Connected
|
||||
Received: 'hello world'
|
|
@ -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 ')
|
||||
|
||||
|
|
Loading…
Reference in New Issue