From 4415d3be1ab10717e1bd3c3fde68b4c04932adda Mon Sep 17 00:00:00 2001 From: Emmanuel Gil Peyrot Date: Tue, 14 Apr 2015 19:19:46 +0200 Subject: XEP-0047: use coroutines for send(), sendall() and the new sendfile(). --- tests/test_stream_xep_0047.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'tests/test_stream_xep_0047.py') diff --git a/tests/test_stream_xep_0047.py b/tests/test_stream_xep_0047.py index 2cc43823..ecba2445 100644 --- a/tests/test_stream_xep_0047.py +++ b/tests/test_stream_xep_0047.py @@ -1,3 +1,4 @@ +import asyncio import threading import time @@ -78,6 +79,7 @@ class TestInBandByteStreams(SlixTest): self.assertEqual(events, set(['ibb_stream_start', 'callback'])) + @asyncio.coroutine def testSendData(self): """Test sending data over an in-band bytestream.""" @@ -115,7 +117,7 @@ class TestInBandByteStreams(SlixTest): # Test sending data out - stream.send("Testing") + yield from stream.send("Testing") self.send("""