def test_get_contribution_with_creator(self): view = SingleCommentAPIView() view.get_contribution( self.creator, self.project.id, self.contribution.id )
def test_get_contribution_with_some_dude(self): some_dude = UserFactory.create() view = SingleCommentAPIView() view.get_contribution( some_dude, self.project.id, self.contribution.id )
def test_get_contribution_with_admin(self): view = SingleCommentAPIView() contribution = view.get_contribution( self.admin, self.project.id, self.contribution.id) self.assertEqual(contribution, self.contribution)