[telepathy-gabble/telepathy-gabble-0.8] Test Channel.Type.StreamedMedia.ImmutableStreams

Will Thompson will.thompson at collabora.co.uk
Mon Oct 19 07:31:11 PDT 2009


---
 tests/twisted/constants.py                  |    1 +
 tests/twisted/jingle/initial-audio-video.py |    6 ++++++
 2 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/tests/twisted/constants.py b/tests/twisted/constants.py
index 1014e92..83ccef7 100644
--- a/tests/twisted/constants.py
+++ b/tests/twisted/constants.py
@@ -46,6 +46,7 @@ INTERFACES = CHANNEL + '.Interfaces'
 
 INITIAL_AUDIO = CHANNEL_TYPE_STREAMED_MEDIA + '.InitialAudio'
 INITIAL_VIDEO = CHANNEL_TYPE_STREAMED_MEDIA + '.InitialVideo'
+IMMUTABLE_STREAMS = CHANNEL_TYPE_STREAMED_MEDIA + '.ImmutableStreams'
 
 CONN = "org.freedesktop.Telepathy.Connection"
 CONN_IFACE_AVATARS = CONN + '.Interface.Avatars'
diff --git a/tests/twisted/jingle/initial-audio-video.py b/tests/twisted/jingle/initial-audio-video.py
index a13be70..d1b5caa 100644
--- a/tests/twisted/jingle/initial-audio-video.py
+++ b/tests/twisted/jingle/initial-audio-video.py
@@ -168,6 +168,12 @@ def incoming(jp, q, bus, conn, stream):
         assertEquals(a, props[cs.INITIAL_AUDIO])
         assertEquals(v, props[cs.INITIAL_VIDEO])
 
+        # FIXME: This doesn't check non-Google contacts that can only do one
+        # media type, as such contacts as simulated by JingleTest2 can always
+        # do both.
+        assertEquals(not jp.can_do_video() or not jp.can_do_video_only(),
+            props[cs.IMMUTABLE_STREAMS])
+
         chan = wrap_channel(bus.get_object(conn.bus_name, path),
             cs.CHANNEL_TYPE_STREAMED_MEDIA)
         chan.Close()
-- 
1.5.6.5




More information about the telepathy-commits mailing list