def test_vote_to_comment(): user = User("a") comment = Comment("dummy") assert comment.receive_vote_from(user) == user.vote_to_comment(comment)
def test_receive_vote_from(): comment1 = Comment(body, voted_users) accept = voted_users + ["cccc"] comment1.receive_vote_from("cccc") assert comment1.voted_users == accept