Esempio n. 1
0
 def wait_agency_for_idle(self, agency, timeout, freq=0.5):
     try:
         check = lambda: self.is_agency_idle(agency)
         yield self.wait_for(check, timeout, freq)
     except unittest.FailTest:
         for agent in agency.get_agents():
             activity = agent.show_activity()
             if activity is None:
                 continue
             self.info(activity)
         raise
Esempio n. 2
0
 def is_agency_idle(self, agency):
     return all([agent.is_idle() for agent in agency.get_agents()])