def test_user_in_roster_case_sensitivity(self):
        # Test that if Core stores the email adddress with Upper case letters
        # and Postorius stores it in lower case, the matching works.
        self.assertTrue(
            user_is_in_list_roster(self.user1, self.mlist, 'members'))

        self.assertTrue(
            user_is_in_list_roster(self.user2, self.mlist, 'members'))
Example #2
0
def user_is_list_moderator(user, mlist):
    return user_is_in_list_roster(user, get_list(mlist), 'moderators')
Example #3
0
def user_is_list_owner(user, mlist):
    return user_is_in_list_roster(user, get_list(mlist), 'owners')
Example #4
0
def user_is_list_moderator(user, mlist):
    """
    Given a User object and a MailingList object/identifier, return True if
    the user is one of the list moderators, False otherwise.
    """
    return user_is_in_list_roster(user, get_list(mlist), 'moderators')
Example #5
0
def user_is_list_owner(user, mlist):
    """
    Given a User object and a MailingList object/identifier, returns True if
    the user is an owner of the given MailingList False otherwise.
    """
    return user_is_in_list_roster(user, get_list(mlist), 'owners')