def review(author, user):
    return factories.ReviewFactory(author=author, user=user)
 def get(self, **kwargs):
     return factories.ReviewFactory(**kwargs)
def test_comment_model_method_works(db, method):
    user = f.UserFactory(email='*****@*****.**', password='******')
    restaurant = f.RestaurantFactory(lat=23.2223443, lon=-243.222334)
    review = f.ReviewFactory(restaurant=restaurant, user=user.profile)
    comment = f.CommentFactory(review=review, user=user.profile)
    assert getattr(comment, method)