[Telepathy-commits] [telepathy-gabble/master] muc/test-muc-properties.py: use make_muc_presence
Guillaume Desmottes
guillaume.desmottes at collabora.co.uk
Thu Mar 12 04:15:18 PDT 2009
---
tests/twisted/muc/test-muc-properties.py | 10 ++--------
1 files changed, 2 insertions(+), 8 deletions(-)
diff --git a/tests/twisted/muc/test-muc-properties.py b/tests/twisted/muc/test-muc-properties.py
index 075f589..e047611 100644
--- a/tests/twisted/muc/test-muc-properties.py
+++ b/tests/twisted/muc/test-muc-properties.py
@@ -7,7 +7,7 @@ import dbus
from twisted.words.xish import domish, xpath
-from gabbletest import go, make_result_iq, acknowledge_iq
+from gabbletest import go, make_result_iq, acknowledge_iq, make_muc_presence
from servicetest import call_async, lazy, match
@match('dbus-signal', signal='StatusChanged', args=[0, 1])
@@ -44,13 +44,7 @@ def expect_members_changed1(event, data):
@match('stream-presence', to='chat at conf.localhost/test')
def expect_presence(event, data):
# Send presence for own membership of room.
- presence = domish.Element((None, 'presence'))
- presence['from'] = 'chat at conf.localhost/test'
- x = presence.addElement(('http://jabber.org/protocol/muc#user', 'x'))
- item = x.addElement('item')
- item['affiliation'] = 'owner'
- item['role'] = 'moderator'
- data['stream'].send(presence)
+ data['stream'].send(make_muc_presence('owner', 'moderator', 'chat at conf.localhost', 'test'))
return True
def add_field(elem, type, var, value):
--
1.5.6.5
More information about the telepathy-commits
mailing list