[telepathy-gabble/master] offer-muc-stream-tube: block the transport until we check the access control
Guillaume Desmottes
guillaume.desmottes at collabora.co.uk
Thu May 7 07:44:53 PDT 2009
We need to block it to ensure that the access control byte has not be
read yet.
---
tests/twisted/tubes/offer-muc-stream-tube.py | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/tests/twisted/tubes/offer-muc-stream-tube.py b/tests/twisted/tubes/offer-muc-stream-tube.py
index 26ecd1f..01fdeab 100644
--- a/tests/twisted/tubes/offer-muc-stream-tube.py
+++ b/tests/twisted/tubes/offer-muc-stream-tube.py
@@ -195,7 +195,7 @@ def test(q, bus, conn, stream, bytestream_cls,
use_tube(q, bytestream, protocol)
# offer a stream tube to another room (new API)
- address = t.create_server(q, address_type)
+ address = t.create_server(q, address_type, block_reading=True)
call_async(q, conn.Requests, 'CreateChannel',
{cs.CHANNEL_TYPE: cs.CHANNEL_TYPE_STREAM_TUBE,
@@ -326,6 +326,8 @@ def test(q, bus, conn, stream, bytestream_cls,
assert handle == bob_handle
protocol = socket_event.protocol
+ # start to read from the transport so we can read the control byte
+ protocol.transport.startReading()
t.check_new_connection_access(q, access_control, access, protocol)
# handle iq_event
--
1.5.6.5
More information about the telepathy-commits
mailing list