def test_get_dv(self): """ Tests the get_dv function to see if the function returns the correct number down votes for a given post """ with project.app.app_context(): self.assertEqual(Votes.get_dv(1), 0)
def getDownVotes(postID): """Retreives the number of down votes for a given post Args: postID:Votes - the post ID from which the down votes is required Return: number of upvotes Raises: """ return Votes.get_dv(postID)