Exemplo n.º 1
0
 def test_city_state_country(self):
     """Test city, state, country format."""
     tested_location = location("Chicago", "United States of America",
                                "Illinois")
     self.assertEqual(tested_location,
                      "Chicago, Illinois, United States Of America")
Exemplo n.º 2
0
 def test_city_country(self):
     """Test whether a city, country format works."""
     tested_location = location("montreal", "canada")
     self.assertEqual(tested_location, 'Montreal, Canada')
Exemplo n.º 3
0
	def test_city_country_population(self):
		place = location('santiago','chile',5000000)
		self.assertEqual(place,'Santiago, Chile - population 5000000')
Exemplo n.º 4
0
	def test_city_country(self):
		place = location('santiago','chile')
		self.assertEqual(place,'Santiago, Chile')
Exemplo n.º 5
0
 def test_city_country_populations(self):
     """Do city, country, and population data work"""
     locale = location('Chicago', 'USA', 2716000)
     self.assertEqual(locale, 'Chicago, USA - population 2716000')
Exemplo n.º 6
0
 def test_city_locations(self):
     """Do city and country names work?"""
     locale = location('Chicago', 'USA')
     self.assertEqual(locale, 'Chicago, USA')
Exemplo n.º 7
0
 def test_city_country(self):
     formatted_location = location('san francisco', 'california')
     self.assertEqual(formatted_location, 'San Francisco, California')
Exemplo n.º 8
0
 def test_city_country_population(self):
     formatted_location = location('fremont', 'california', 30000)
     self.assertEqual(formatted_location,
                      'Fremont, California - Population = 30000')
Exemplo n.º 9
0
 def test_city_country(self):
     """Does the output look like 'Santiago, Chile'."""
     formatted_location = location('santiago', 'chile')
     self.assertEqual(formatted_location, 'Santiago, Chile')
Exemplo n.º 10
0
 def test_city_country(self):
     mylocation = location('Santiago', 'Chile')
     self.assertEqual(mylocation, 'Santiago,Chile')
Exemplo n.º 11
0
 def test_city_country_population(self):
     info = location('Santiago', 'Chile', 5000000)
     self.assertEqual(info, 'Santiago,Chile - 5000000')
Exemplo n.º 12
0
 def test_location(self):
     """Do locations like 'London, England' work?"""
     formatted_location = location('london', 'england')
     self.assertEqual(formatted_location, 'London, England')
Exemplo n.º 13
0
 def test_location_demographics(self):
     """Do locations with populations like 'London, England, population: 8.7 million' work?"""
     formatted_location = location('london', 'england', '8.7 million')
     self.assertEqual(formatted_location,
                      'London, England, population: 8.7 million')