summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonny Lamb <jonny.lamb@collabora.co.uk>2011-09-02 16:38:43 +0100
committerJonny Lamb <jonny.lamb@collabora.co.uk>2011-09-02 16:40:15 +0100
commit00a7c2fb7195374c39f2b9c9be8254822e5484e8 (patch)
tree532432cd8823bd826b00c4a751dfded3d14088b6
parentadea0ce7c2e48190fcf18c11717380e551432e04 (diff)
caps_helper: give data forms back to disco utility functions
Signed-off-by: Jonny Lamb <jonny.lamb@collabora.co.uk>
-rw-r--r--tests/twisted/caps/advertise-contact-caps.py26
-rw-r--r--tests/twisted/caps/advertise-legacy.py14
-rw-r--r--tests/twisted/caps/initial-caps.py2
-rw-r--r--tests/twisted/caps/tube-caps.py2
-rw-r--r--tests/twisted/caps_helper.py2
5 files changed, 23 insertions, 23 deletions
diff --git a/tests/twisted/caps/advertise-contact-caps.py b/tests/twisted/caps/advertise-contact-caps.py
index 55630d3e..8affe93b 100644
--- a/tests/twisted/caps/advertise-contact-caps.py
+++ b/tests/twisted/caps/advertise-contact-caps.py
@@ -46,7 +46,7 @@ def run_test(q, bus, conn, stream,
args=[cs.CONN_STATUS_CONNECTED, cs.CSR_REQUESTED]),
EventPattern('stream-presence'),
)
- (disco_response, namespaces) = disco_caps(q, stream, initial_presence)
+ (disco_response, namespaces, _) = disco_caps(q, stream, initial_presence)
check_caps(namespaces, [ns.TUBES + '/stream#x-abiword'])
conn.ContactCapabilities.UpdateCapabilities([
@@ -70,7 +70,7 @@ def run_test(q, bus, conn, stream,
media_interface + '/video/h264',
]),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, JINGLE_CAPS + [ns.TUBES + '/stream#x-abiword'])
@@ -87,7 +87,7 @@ def run_test(q, bus, conn, stream,
media_interface + '/ice-udp',
]),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces,
JINGLE_CAPS_EXCEPT_GVIDEO + [ns.TUBES + '/stream#x-abiword'])
@@ -96,7 +96,7 @@ def run_test(q, bus, conn, stream,
conn.ContactCapabilities.UpdateCapabilities([
(cs.CLIENT + '.AbiWord', [], []),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, JINGLE_CAPS_EXCEPT_GVIDEO)
@@ -104,7 +104,7 @@ def run_test(q, bus, conn, stream,
conn.ContactCapabilities.UpdateCapabilities([
(cs.CLIENT + '.KCall', [], []),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [])
@@ -124,7 +124,7 @@ def run_test(q, bus, conn, stream,
media_interface + '/video/h264',
]),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [ns.TUBES + '/stream#x-abiword'])
@@ -132,7 +132,7 @@ def run_test(q, bus, conn, stream,
conn.ContactCapabilities.UpdateCapabilities([
(cs.CLIENT + '.AbiWord', [], []),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [])
@@ -148,7 +148,7 @@ def run_test(q, bus, conn, stream,
initial_audio: True},
], [media_interface + '/gtalk-p2p']),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces,
[ns.GOOGLE_P2P, ns.JINGLE_TRANSPORT_RAWUDP, ns.JINGLE,
@@ -164,7 +164,7 @@ def run_test(q, bus, conn, stream,
initial_audio: True},
], [])
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces,
[ns.JINGLE_TRANSPORT_RAWUDP, ns.JINGLE,
@@ -183,7 +183,7 @@ def run_test(q, bus, conn, stream,
media_interface + '/video/theora',
]),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces,
[ns.JINGLE_TRANSPORT_ICEUDP, ns.JINGLE_TRANSPORT_RAWUDP, ns.JINGLE,
@@ -194,7 +194,7 @@ def run_test(q, bus, conn, stream,
conn.ContactCapabilities.UpdateCapabilities([
(cs.CLIENT + '.KCall', [], []),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [])
@@ -205,7 +205,7 @@ def run_test(q, bus, conn, stream,
cs.TARGET_HANDLE_TYPE: cs.HT_CONTACT,
}], []),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [ns.FILE_TRANSFER])
@@ -235,7 +235,7 @@ def run_mixed_test (q, bus, conn, stream):
]),
])
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, JINGLE_CAPS)
diff --git a/tests/twisted/caps/advertise-legacy.py b/tests/twisted/caps/advertise-legacy.py
index b16c7c07..8c386321 100644
--- a/tests/twisted/caps/advertise-legacy.py
+++ b/tests/twisted/caps/advertise-legacy.py
@@ -27,7 +27,7 @@ def run_test(q, bus, conn, stream):
(cs.CHANNEL_TYPE_STREAM_TUBE, 2L**32-1)]
remove = []
caps = conn.Capabilities.AdvertiseCapabilities(add, remove)
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, JINGLE_CAPS)
@@ -36,7 +36,7 @@ def run_test(q, bus, conn, stream):
remove = [cs.CHANNEL_TYPE_STREAMED_MEDIA,
cs.CHANNEL_TYPE_STREAM_TUBE]
caps = conn.Capabilities.AdvertiseCapabilities(add, remove)
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [])
@@ -50,7 +50,7 @@ def run_test(q, bus, conn, stream):
cs.MEDIA_CAP_AUDIO | cs.MEDIA_CAP_GTALKP2P)]
remove = []
caps = conn.Capabilities.AdvertiseCapabilities(add, remove)
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces,
[ns.GOOGLE_P2P, ns.JINGLE_TRANSPORT_RAWUDP, ns.JINGLE,
@@ -62,7 +62,7 @@ def run_test(q, bus, conn, stream):
remove = [cs.CHANNEL_TYPE_STREAMED_MEDIA,
cs.CHANNEL_TYPE_STREAM_TUBE]
caps = conn.Capabilities.AdvertiseCapabilities(add, remove)
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [])
@@ -71,7 +71,7 @@ def run_test(q, bus, conn, stream):
add = [(cs.CHANNEL_TYPE_STREAMED_MEDIA, cs.MEDIA_CAP_AUDIO)]
remove = []
caps = conn.Capabilities.AdvertiseCapabilities(add, remove)
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces,
[ns.JINGLE_TRANSPORT_RAWUDP, ns.JINGLE,
@@ -83,7 +83,7 @@ def run_test(q, bus, conn, stream):
remove = [cs.CHANNEL_TYPE_STREAMED_MEDIA,
cs.CHANNEL_TYPE_STREAM_TUBE]
caps = conn.Capabilities.AdvertiseCapabilities(add, remove)
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces, [])
@@ -93,7 +93,7 @@ def run_test(q, bus, conn, stream):
cs.MEDIA_CAP_VIDEO | cs.MEDIA_CAP_ICEUDP)]
remove = []
caps = conn.Capabilities.AdvertiseCapabilities(add, remove)
- (disco_response, namespaces, _) = receive_presence_and_ask_caps(q, stream,
+ (disco_response, namespaces, _, _) = receive_presence_and_ask_caps(q, stream,
False)
check_caps(namespaces,
[ns.JINGLE_TRANSPORT_ICEUDP, ns.JINGLE_TRANSPORT_RAWUDP, ns.JINGLE,
diff --git a/tests/twisted/caps/initial-caps.py b/tests/twisted/caps/initial-caps.py
index 8d50f0ee..6aef228b 100644
--- a/tests/twisted/caps/initial-caps.py
+++ b/tests/twisted/caps/initial-caps.py
@@ -15,7 +15,7 @@ import ns
def run_test(q, bus, conn, stream):
initial_presence = q.expect('stream-presence')
- _, namespaces = disco_caps(q, stream, initial_presence)
+ _, namespaces, _ = disco_caps(q, stream, initial_presence)
# For some reason, until we advertise any capabilities, these caps turn
# up in our presence
diff --git a/tests/twisted/caps/tube-caps.py b/tests/twisted/caps/tube-caps.py
index a70f286d..3d3f698d 100644
--- a/tests/twisted/caps/tube-caps.py
+++ b/tests/twisted/caps/tube-caps.py
@@ -232,7 +232,7 @@ def advertise_caps(q, conn, stream, filters, expected_features, unexpected_featu
[(cs.CLIENT + '.Foo', filters, [])])
# Expect Gabble to reply with the correct caps
- event, namespaces, signaled_caps = receive_presence_and_ask_caps(q, stream)
+ event, namespaces, _, signaled_caps = receive_presence_and_ask_caps(q, stream)
assertSameElements(expected_caps, signaled_caps)
diff --git a/tests/twisted/caps_helper.py b/tests/twisted/caps_helper.py
index 85013850..817dd03a 100644
--- a/tests/twisted/caps_helper.py
+++ b/tests/twisted/caps_helper.py
@@ -265,7 +265,7 @@ def disco_caps(q, stream, presence):
# Check if the hash matches the announced capabilities
assertEquals(compute_caps_hash(identities, features, dataforms), ver)
- return (event, features)
+ return (event, features, dataforms)
def caps_contain(event, cap):
node = xpath.queryForNodes('/iq/query/feature[@var="%s"]'