telepathy-gabble: stop using GetAliases()
Guillaume Desmottes
gdesmott at kemper.freedesktop.org
Fri Oct 11 14:58:34 PDT 2013
Module: telepathy-gabble
Branch: master
Commit: 4f7830a1aea32c1aacbfa45cea2fae573e02a507
URL: http://cgit.freedesktop.org/telepathy/telepathy-gabble/commit/?id=4f7830a1aea32c1aacbfa45cea2fae573e02a507
Author: Guillaume Desmottes <guillaume.desmottes at collabora.co.uk>
Date: Wed Oct 9 16:41:56 2013 -0400
stop using GetAliases()
---
tests/twisted/roster/test-save-alias-to-roster.py | 3 ++-
tests/twisted/vcard/test-alias-message.py | 6 +++++-
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/tests/twisted/roster/test-save-alias-to-roster.py b/tests/twisted/roster/test-save-alias-to-roster.py
index f8c0c2a..0f67da0 100644
--- a/tests/twisted/roster/test-save-alias-to-roster.py
+++ b/tests/twisted/roster/test-save-alias-to-roster.py
@@ -91,7 +91,8 @@ def test(q, bus, conn, stream):
q.expect('dbus-signal', signal='MembersChangedDetailed')
# But if we ask for it, Gabble should probably send a PEP query.
- assertEquals(jid, conn.Aliasing.GetAliases([handle])[handle])
+ h2asv = conn.Contacts.GetContactAttributes([handle], [cs.CONN_IFACE_ALIASING], False)
+ assertEquals(jid, h2asv[handle][cs.ATTR_ALIAS])
event = q.expect('stream-iq', iq_type='get', query_ns=ns.PUBSUB, to=jid)
nick = 'Constant Future'
diff --git a/tests/twisted/vcard/test-alias-message.py b/tests/twisted/vcard/test-alias-message.py
index 39c9b27..07f889b 100644
--- a/tests/twisted/vcard/test-alias-message.py
+++ b/tests/twisted/vcard/test-alias-message.py
@@ -15,7 +15,11 @@ import constants as cs
import ns
def get_aliases(conn, contacts):
- return conn.Aliasing.GetAliases(contacts)
+ h2asv = conn.Contacts.GetContactAttributes(contacts, [cs.CONN_IFACE_ALIASING], False)
+ ret = {}
+ for h in contacts:
+ ret[h] = h2asv[h][cs.ATTR_ALIAS]
+ return ret
def test(q, bus, conn, stream):
expect_and_handle_get_vcard(q, stream)
More information about the telepathy-commits
mailing list