def target_comment(self, target_group, user): wrong_user = UserFactory() comment = CommentFactory(comment_group_id=target_group.id, user_id=wrong_user.id, user=wrong_user, status=CommentStatus.DELETED) return comment
def comment_obj(self, content): comment = CommentFactory.build(content=content) return comment
def comment_obj(self): comment = CommentFactory.build() return comment
def target_comment(self, target_group, user): comment = CommentFactory(comment_group_id=target_group.id, user_id=user.id, user=user, status=CommentStatus.DELETED) return comment
def target_comment(self, target_group, user): comment = CommentFactory(comment_group_id=target_group.id, user_id=user.id, user=user) return comment
def comment_obj(self, parent_comment): comment = CommentFactory.build(parent_id=parent_comment.id) return comment
def comment_obj(self, parent_comment): wrong_id = parent_comment.id + 123 comment = CommentFactory.build(parent_id=wrong_id) return comment
def comment(self, logged_in_user): return CommentFactory.create(author=logged_in_user.id)
def parent_comment(self, target_comment_group): comment = CommentFactory(comment_group_id=target_comment_group.id) return comment
def comment(self): return CommentFactory.create()
def comment(self, post): return CommentFactory.create(post=post, is_reply=False)
def comment(self, post): return CommentFactory.create(post=post)
def comment(self, post, logged_in_user): return CommentFactory.create(post=post, likes=[str(logged_in_user.id)])
def comment(self, post, logged_in_user): return CommentFactory.create(post=post, author=logged_in_user)