Exemple #1
0
 def test_next_with_correct_aks(self):
     scheduler = RoundRobinScheduler(['wwx6xhe8aQncZZUm7QsIPXKI', '9ea66EnDo1YLFuzu5QDDp4zU'])
     self.assertEqual(scheduler.next(), 'wwx6xhe8aQncZZUm7QsIPXKI')
     self.assertEqual(scheduler.next(), '9ea66EnDo1YLFuzu5QDDp4zU')
     self.assertEqual(scheduler.next(), 'wwx6xhe8aQncZZUm7QsIPXKI')
 def setUp(self):
     self.scheduler = RoundRobinScheduler(
         ['wwx6xhe8aQncZZUm7QsIPXKI', '9ea66EnDo1YLFuzu5QDDp4zU'])
     self.location_api = LocationApi(self.scheduler)
Exemple #3
0
 def test_next_with_empty_aks(self):
     scheduler = RoundRobinScheduler([])
     with self.assertRaises(ParamError):
         scheduler.next()
Exemple #4
0
 def setUp(self):
     self.scheduler = RoundRobinScheduler(
         ['wwx6xhe8aQncZZUm7QsIPXKI', '9ea66EnDo1YLFuzu5QDDp4zU'])
     self.transform_api = TransformApi(self.scheduler)
Exemple #5
0
 def test_next_with_correct_aks(self):
     scheduler = RoundRobinScheduler(
         ['wwx6xhe8aQncZZUm7QsIPXKI', '9ea66EnDo1YLFuzu5QDDp4zU'])
     self.assertEqual(scheduler.next(), 'wwx6xhe8aQncZZUm7QsIPXKI')
     self.assertEqual(scheduler.next(), '9ea66EnDo1YLFuzu5QDDp4zU')
     self.assertEqual(scheduler.next(), 'wwx6xhe8aQncZZUm7QsIPXKI')
Exemple #6
0
 def test_next_with_empty_aks(self):
     scheduler = RoundRobinScheduler([])
     with self.assertRaises(ParamError):
         scheduler.next()
Exemple #7
0
 def setUp(self):
     self.scheduler = RoundRobinScheduler(
         ['wwx6xhe8aQncZZUm7QsIPXKI', '9ea66EnDo1YLFuzu5QDDp4zU'])
     self.place_api = PlaceApi(self.scheduler)