[Telepathy-commits] [telepathy-salut/master] test-caps-tubes.py: Do not assume the contact handle is 2.

Alban Crequy alban.crequy at collabora.co.uk
Thu Feb 26 11:20:12 PST 2009


---
 tests/twisted/avahi/test-caps-tubes.py |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/tests/twisted/avahi/test-caps-tubes.py b/tests/twisted/avahi/test-caps-tubes.py
index 16c00b6..7e9a0b4 100644
--- a/tests/twisted/avahi/test-caps-tubes.py
+++ b/tests/twisted/avahi/test-caps-tubes.py
@@ -195,7 +195,7 @@ def caps_contain(event, cap):
     return var == cap
 
 def test_tube_caps_from_contact(q, bus, conn, service,
-        contact, contact_handle, client):
+        client):
 
     conn_caps_iface = dbus.Interface(conn, caps_iface)
     conn_contacts_iface = dbus.Interface(conn, contacts_iface)
@@ -220,6 +220,8 @@ def test_tube_caps_from_contact(q, bus, conn, service,
     assert query_node.attributes['node'] == \
         client + '#' + ver, (query_node.attributes['node'], client, ver)
 
+    contact_handle = conn.RequestHandles(HT_CONTACT, [contact_name])[0]
+
     # send good reply
     result = make_result_iq(event.stanza)
     query = result.firstChildElement()
@@ -726,7 +728,7 @@ def test(q, bus, conn):
     client = 'http://telepathy.freedesktop.org/fake-client'
 
     test_tube_caps_from_contact(q, bus, conn, service,
-            'bilbo1 at foo.com/Foo', 2L, client)
+            client)
 
     test_tube_caps_to_contact(q, bus, conn, service)
 
-- 
1.5.6.5




More information about the telepathy-commits mailing list