summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorChris Liechti <cliechti@gmx.net>2015-09-22 23:24:35 +0200
committerChris Liechti <cliechti@gmx.net>2015-09-22 23:24:35 +0200
commit16843852842bf0603b215ed93f8c0490571c8dbc (patch)
tree1250de18a41dfbd90727a93ee81f691c72c350b6 /test
parentc2b26798cb0bf3a6db8f09a0e030dc725356fc48 (diff)
downloadpyserial-git-16843852842bf0603b215ed93f8c0490571c8dbc.tar.gz
fix deprecated function, unicode in testv3.0a0
Diffstat (limited to 'test')
-rw-r--r--test/test_iolib.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/test_iolib.py b/test/test_iolib.py
index 37ee081..f5635f3 100644
--- a/test/test_iolib.py
+++ b/test/test_iolib.py
@@ -63,10 +63,10 @@ class Test_SerialAndIO(unittest.TestCase):
self.s.close()
def test_hello_raw(self):
- self.io.write(r"hello\n")
+ self.io.write(b"hello\n".decode('utf-8'))
self.io.flush() # it is buffering. required to get the data out
hello = self.io.readline()
- self.failUnlessEqual(hello, u"hello\n")
+ self.failUnlessEqual(hello, b"hello\n".decode('utf-8'))
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
if __name__ == '__main__':