Only once at the beginning and end of execution request

 

 

 

 

def on_start(self):

""" on_start is called when a Locust start before any task is scheduled """

  self.login()

 

def on_stop(self):

 """ on_stop is called when the TaskSet is stopping """

   self.logout()

 

Guess you like

Origin www.cnblogs.com/kaibindirver/p/11774651.html