Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(5)  |  Call(5)  |  Derive(0)  |  Import(0)

src/b/a/babble.client-2.0/src/babble/client/browser/chat.py   babble.client(Download)
    def render_chat_box(self, chat_id, box_id, tzoffset):
        """ """
        chat_type, audience = chat_id.split('_', 1)
        response = utils.get_last_conversation(
                                        self.context,

src/b/a/babble.client-2.0/src/babble/client/tests/test_chat.py   babble.client(Download)
        self.assertEquals(resp['status'], config.AUTH_FAIL)
 
        messages = utils.get_last_conversation(portal, username1)
        self.assertEquals(messages['status'], config.AUTH_FAIL)
 
        self.assertRaises(AttributeError, method, *pars)
 
        messages = utils.get_last_conversation(portal, username1)
        self.assertEquals(messages['status'], config.ERROR)
 
 
        # Also test that utils' get_last_conversation returns this message
        messages = utils.get_last_conversation(portal, username2)
        self.assertEquals(messages.keys(), ['status', 'messages', 'last_msg_date', 'chatroom_messages'])
        self.assertEquals(messages['status'], config.SUCCESS)
        self.assertEquals(resp['status'], config.SUCCESS)
 
        messages = utils.get_last_conversation(portal, username2)
 
        check = {'status': config.SUCCESS, 'last_msg_date': message_timestamp, 'messages':{}, 'chatroom_messages': {}}