Example #1
0
class WebPageTasks(TaskSet):
    def on_start(self):
        self.test_runner = LocustRunner(self.client)
        self.file_path = self.locust.file_path

    @task
    def test_specified_scenario(self):
        self.test_runner.run(self.file_path)
Example #2
0
 def test_LocustRunner(self):
     testcase_file = os.path.join(os.getcwd(), 'tests', 'httpbin',
                                  'basic.yml')
     locust_runner = LocustRunner(self.locust_client)
     locust_runner.run(testcase_file)
Example #3
0
 def on_start(self):
     self.test_runner = LocustRunner(self.client)
     self.file_path = self.locust.file_path