[Telepathy-commits] [telepathy-gabble/master] Remove vcard/test-muc-alias.py

Will Thompson will.thompson at collabora.co.uk
Mon Mar 16 12:14:06 PDT 2009


muc/test-muc-alias.py tests everything this test does, and more. Indeed,
the vcard/ variant doesn't even *mention* vCards. :-)
---
 tests/twisted/Makefile.am             |    1 -
 tests/twisted/vcard/test-muc-alias.py |   79 ---------------------------------
 2 files changed, 0 insertions(+), 80 deletions(-)
 delete mode 100644 tests/twisted/vcard/test-muc-alias.py

diff --git a/tests/twisted/Makefile.am b/tests/twisted/Makefile.am
index 06ef790..4bf0d67 100644
--- a/tests/twisted/Makefile.am
+++ b/tests/twisted/Makefile.am
@@ -65,7 +65,6 @@ TWISTED_TESTS = \
 	vcard/test-avatar.py \
 	vcard/test-avatar-retrieved.py \
 	vcard/test-avatar-tokens.py \
-	vcard/test-muc-alias.py \
 	vcard/test-save-alias-to-vcard.py \
 	vcard/test-set-alias.py \
 	vcard/test-vcard-cache.py \
diff --git a/tests/twisted/vcard/test-muc-alias.py b/tests/twisted/vcard/test-muc-alias.py
deleted file mode 100644
index 4ebe4f4..0000000
--- a/tests/twisted/vcard/test-muc-alias.py
+++ /dev/null
@@ -1,79 +0,0 @@
-
-"""
-Test support for aliases in MUCs.
-"""
-
-import dbus
-
-from twisted.words.xish import domish
-
-from gabbletest import go, make_result_iq, make_muc_presence
-from servicetest import call_async, lazy, match, tp_name_prefix
-
-def aliasing_iface(proxy):
-    return dbus.Interface(proxy, tp_name_prefix +
-        '.Connection.Interface.Aliasing')
-
- at match('dbus-signal', signal='StatusChanged', args=[0, 1])
-def expect_connected(event, data):
-    # Need to call this asynchronously as it involves Gabble sending us a
-    # query.
-    call_async(data['test'], data['conn_iface'], 'RequestHandles', 2,
-        ['chat at conf.localhost'])
-    return True
-
- at match('stream-iq', to='conf.localhost',
-    query_ns='http://jabber.org/protocol/disco#info')
-def expect_disco(event, data):
-    result = make_result_iq(data['stream'], event.stanza)
-    feature = result.firstChildElement().addElement('feature')
-    feature['var'] = 'http://jabber.org/protocol/muc'
-    data['stream'].send(result)
-    return True
-
- at match('dbus-return', method='RequestHandles')
-def expect_request_handles_return(event, data):
-    handles = event.value[0]
-
-    call_async(data['test'], data['conn_iface'], 'RequestChannel',
-        'org.freedesktop.Telepathy.Channel.Type.Text', 2, handles[0], True)
-    return True
-
- at lazy
- at match('dbus-signal', signal='MembersChanged',
-    args=[u'', [], [], [], [2], 0, 0])
-def expect_members_changed1(event, data):
-    return True
-
- at match('stream-presence', to='chat at conf.localhost/test')
-def expect_presence(event, data):
-    # Send presence for other member of room.
-    data['stream'].send(make_muc_presence('owner', 'moderator', 'chat at conf.localhost', 'bob'))
-
-    # Send presence for own membership of room.
-    data['stream'].send(make_muc_presence('none', 'participant', 'chat at conf.localhost', 'test'))
-    return True
-
- at match('dbus-signal', signal='MembersChanged',
-    args=[u'', [2, 3], [], [], [], 0, 0])
-def expect_members_changed2(event, data):
-    assert data['conn_iface'].InspectHandles(1, [2]) == [
-        'chat at conf.localhost/test']
-    assert data['conn_iface'].InspectHandles(1, [3]) == [
-        'chat at conf.localhost/bob']
-
-    return True
-
- at match('dbus-return', method='RequestChannel')
-def expect_request_channel_return(event, data):
-    assert aliasing_iface(data['conn']).RequestAliases([3]) == ['bob']
-    data['conn_iface'].Disconnect()
-    return True
-
- at match('dbus-signal', signal='StatusChanged', args=[2, 1])
-def expect_disconnected(event, data):
-    return True
-
-if __name__ == '__main__':
-    go()
-
-- 
1.5.6.5




More information about the telepathy-commits mailing list