[Python-3000-checkins] r57662 - python/branches/py3k/Lib/test/test_asynchat.py
jeremy.hylton
python-3000-checkins at python.org
Wed Aug 29 16:56:41 CEST 2007
Author: jeremy.hylton
Date: Wed Aug 29 16:56:40 2007
New Revision: 57662
Modified:
python/branches/py3k/Lib/test/test_asynchat.py
Log:
Fix test failures caused by missing/incorrect conversion to bytes.
Modified: python/branches/py3k/Lib/test/test_asynchat.py
==============================================================================
--- python/branches/py3k/Lib/test/test_asynchat.py (original)
+++ python/branches/py3k/Lib/test/test_asynchat.py Wed Aug 29 16:56:40 2007
@@ -90,8 +90,8 @@
time.sleep(0.5) # Give server time to initialize
c = echo_client(term)
c.push(b"hello ")
- c.push(bytes("world%s" % term))
- c.push(bytes("I'm not dead yet!%s" % term))
+ c.push(bytes("world%s" % term, "ascii"))
+ c.push(bytes("I'm not dead yet!%s" % term, "ascii"))
c.push(SERVER_QUIT)
asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01)
s.join()
@@ -185,7 +185,7 @@
s.start()
time.sleep(0.5) # Give server time to initialize
c = echo_client(b'\n')
- c.push("hello world\n\nI'm not dead yet!\n")
+ c.push(b"hello world\n\nI'm not dead yet!\n")
c.push(SERVER_QUIT)
asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01)
s.join()
@@ -198,7 +198,7 @@
s.start()
time.sleep(0.5) # Give server time to initialize
c = echo_client(b'\n')
- c.push("hello world\nI'm not dead yet!\n")
+ c.push(b"hello world\nI'm not dead yet!\n")
c.push(SERVER_QUIT)
c.close_when_done()
asyncore.loop(use_poll=self.usepoll, count=300, timeout=.01)
More information about the Python-3000-checkins
mailing list