def test_twitter_with_desc(self): venue = VenueFactory( twitter_handle='myBar', twitter_short_location_description='downtown', ) formatted = format_venue(venue) self.assertEqual(formatted, '@myBar downtown')
def test_twitter_with_desc(self): venue = VenueFactory( twitter_handle="myBar", twitter_short_location_description="downtown", ) formatted = format_venue(venue) self.assertEqual(formatted, "@myBar downtown")
def test_twitter_no_desc(self): venue = VenueFactory(twitter_handle='mytwitter') formatted = format_venue(venue) self.assertEqual(formatted, '@mytwitter')
def test_no_twitter(self): venue = VenueFactory(twitter_handle='') formatted = format_venue(venue) self.assertEqual(formatted, venue.name)