Пример #1
0
    def test_format_group_join_request(self):
        detail = group_join_request_to_json('group_join', self.group.id, 'join_request_msg')
        notice = UserNotification.objects.add_group_join_request_notice('group_join',
                                                                        detail=detail)
        resp = Command().format_group_join_request(notice)

        assert resp.grpjoin_group_url == '/#group/%(group_id)s/members/' % {'group_id': self.group.id}
Пример #2
0
 def test_format_group_join_request(self):
     detail = group_join_request_to_json('group_join', self.group.id,
                                         'join_request_msg')
     notice = UserNotification.objects.add_group_join_request_notice(
         'group_join', detail=detail)
     msg = notice.format_group_join_request()
     assert '/#group/%(group_id)s/members/' % {
         'group_id': self.group.id
     } in msg