Ejemplo n.º 1
0
 def test_topic_post_moderate_handler(self):
     """
     Create comment that tells what moderation action was made
     """
     topic_post_moderate.send(sender=None,
                              user=self.user,
                              topic=self.topic,
                              action=1)
     self.assertEqual(
         Comment.objects.filter(user=self.user, topic=self.topic,
                                action=1).count(), 1)
Ejemplo n.º 2
0
 def send_signal(self, user, action):
     topic_post_moderate.send(sender=self.topic.__class__,
                              user=user,
                              topic=self.topic,
                              action=action)
Ejemplo n.º 3
0
 def test_topic_post_moderate_handler(self):
     """
     Create comment that tells what moderation action was made
     """
     topic_post_moderate.send(sender=None, user=self.user, topic=self.topic, action=1)
     self.assertEqual(Comment.objects.filter(user=self.user, topic=self.topic, action=1).count(), 1)
Ejemplo n.º 4
0
 def send_signal(self, user, action):
     topic_post_moderate.send(sender=self.topic.__class__, user=user,
                              topic=self.topic, action=action)