Update root_disco_get_info signature
darcs-hash:20070620194034-86b55-5d991717885aa91b5cd2f12a333a0e98eb2ae800.gz
This commit is contained in:
@@ -79,9 +79,10 @@ class MailComponent(FeederComponent):
|
||||
class MailAccountManager(AccountManager):
|
||||
"""JMC specific account behavior"""
|
||||
|
||||
def root_disco_get_info(self, name, category, type):
|
||||
def root_disco_get_info(self, node, name, category, type):
|
||||
"""Add jabber:iq:gateway support"""
|
||||
disco_info = AccountManager.root_disco_get_info(self, name, category, type)
|
||||
disco_info = AccountManager.root_disco_get_info(self, node, name,
|
||||
category, type)
|
||||
disco_info.add_feature("jabber:iq:gateway")
|
||||
disco_info.add_identity(name, "headline", "newmail")
|
||||
return disco_info
|
||||
|
||||
@@ -556,7 +556,7 @@ class SendMailMessageHandler_TestCase(unittest.TestCase):
|
||||
class MailAccountManager_TestCase(unittest.TestCase):
|
||||
def test_root_disco_get_info(self):
|
||||
mam = MailAccountManager(None)
|
||||
disco_info = mam.root_disco_get_info("JMC", "gateway", "smtp")
|
||||
disco_info = mam.root_disco_get_info(None, "JMC", "gateway", "smtp")
|
||||
self.assertTrue(disco_info.has_feature("jabber:iq:gateway"))
|
||||
self.assertEquals(len(disco_info.get_identities()), 2)
|
||||
self.assertTrue(disco_info.identity_is("gateway", "smtp"))
|
||||
|
||||
Reference in New Issue
Block a user