Пример #1
0
 def setup_method(self):
     script.Zone._initialize_zones()
     self.zone = script.Zone.ZONES[0]
     self.graph = script.IncomeGraph()
     self.zones = script.Zone.ZONES
     for _ in range(0, 10):
         self.zone.add_inhabitant(
             script.Agent(script.Position(-180, -89), income=40, age=20))
Пример #2
0
 def setup_method(self):
     script.Zone._initialize_zones()
     self.zone = script.Zone.ZONES[0]
     self.graph = script.AgreeablenessGraph()
     self.zones = script.Zone.ZONES
     for _ in range(0, 10):
         self.zone.add_inhabitant(
             script.Agent(script.Position(-180, -89), agreeableness=1))
Пример #3
0
 def test_latitude_degrees_range(self):
     with pytest.raises(AssertionError):
         position = script.Position(100, 100)
Пример #4
0
 def test_longitude_degrees_range(self):
     with pytest.raises(AssertionError):
         position = script.Position(190, 55)
Пример #5
0
 def test_longitude_degrees_range(self):
     with pytest.raises(AssertionError):
         script.Position(200, 33)
Пример #6
0
 def setup_method(self):
     self.position = script.Position(100, 33)
Пример #7
0
 def setup_method(self):
     self.POSITION = script.Position(100, 33)