def test_non_subscriber_without_good_standing_is_not_approved(self): # Non-subscribers without good standing are not approved to post. message = self.makeMailmanMessage(self.mm_list, self.lp_user_email, 'subject', 'any content.') msg_data = {} silence = LPStanding.process(self.mm_list, message, msg_data) self.assertEqual(None, silence) self.assertFalse('approved' in msg_data)
def test_non_subscriber_without_good_standing_is_not_approved(self): # Non-subscribers without good standing are not approved to post. message = self.makeMailmanMessage( self.mm_list, self.lp_user_email, 'subject', 'any content.') msg_data = {} silence = LPStanding.process(self.mm_list, message, msg_data) self.assertEqual(None, silence) self.assertFalse('approved' in msg_data)
def test_non_subscriber_with_good_standing_is_approved(self): # Non-subscribers with good standing are approved to post. with celebrity_logged_in('admin'): self.lp_user.personal_standing = PersonalStanding.GOOD message = self.makeMailmanMessage(self.mm_list, self.lp_user_email, 'subject', 'any content.') msg_data = {} silence = LPStanding.process(self.mm_list, message, msg_data) self.assertEqual(None, silence) self.assertTrue(msg_data['approved'])
def test_non_subscriber_with_good_standing_is_approved(self): # Non-subscribers with good standing are approved to post. with celebrity_logged_in('admin'): self.lp_user.personal_standing = PersonalStanding.GOOD message = self.makeMailmanMessage( self.mm_list, self.lp_user_email, 'subject', 'any content.') msg_data = {} silence = LPStanding.process(self.mm_list, message, msg_data) self.assertEqual(None, silence) self.assertTrue(msg_data['approved'])