Make roster test a little more robust.

This commit is contained in:
Lance Stout 2011-05-20 21:15:57 -04:00
parent 6b274a2543
commit 4bb226147a

View file

@ -192,7 +192,10 @@ class TestStreamRoster(SleekTest):
"Unexpected roster values: %s" % self.xmpp.roster) "Unexpected roster values: %s" % self.xmpp.roster)
self.recv(""" self.recv("""
<presence from="andré@foo/bar" /> <presence to="tester@localhost" from="andré@foo/bar">
<show>away</show>
<status>Testing</status>
</presence>
""") """)
# Give the event queue time to process. # Give the event queue time to process.
@ -204,8 +207,8 @@ class TestStreamRoster(SleekTest):
'groups': ['Unicode'], 'groups': ['Unicode'],
'presence': { 'presence': {
'bar':{'priority':0, 'bar':{'priority':0,
'status':'', 'status':'Testing',
'show':'available'}}, 'show':'away'}},
'in_roster': True}} 'in_roster': True}}
self.failUnless(self.xmpp.roster == roster, self.failUnless(self.xmpp.roster == roster,
"Unexpected roster values: %s" % self.xmpp.roster) "Unexpected roster values: %s" % self.xmpp.roster)