Commit ddc2048e authored by Benjamin Blanc's avatar Benjamin Blanc

scalability: runScalabilityTestSuite: Change the way to launch suite

Launch one tester per test.
parent 880bf167
...@@ -357,10 +357,14 @@ class ScalabilityLauncher(object): ...@@ -357,10 +357,14 @@ class ScalabilityLauncher(object):
self.log("user_number: %s" %str(user_number)) self.log("user_number: %s" %str(user_number))
self.log("test_duration: %ss" %str(test_duration)) self.log("test_duration: %ss" %str(test_duration))
command = [tester_path, # Generate commands
command_list = []
i = 0
for suite in test_suites:
command_list[i] = [tester_path,
self.__argumentNamespace.erp5_url, self.__argumentNamespace.erp5_url,
str(user_number), str(user_number),
' '.join(test_suites), suite,
'--benchmark-path-list', benchmarks_path, '--benchmark-path-list', benchmarks_path,
'--users-file-path', user_file_path, '--users-file-path', user_file_path,
'--users-file', user_file, '--users-file', user_file,
...@@ -368,11 +372,22 @@ class ScalabilityLauncher(object): ...@@ -368,11 +372,22 @@ class ScalabilityLauncher(object):
'--report-directory', self.__argumentNamespace.log_path, '--report-directory', self.__argumentNamespace.log_path,
'--repeat', "%s" %str(MAX_DOCUMENTS), '--repeat', "%s" %str(MAX_DOCUMENTS),
] ]
self.log("command: %s" %str(command)) i += 1
tester_process = subprocess.Popen(command)
# Launch
tester_process_list = []
for i in range(i,len(command_list)):
self.log("command: %s" %str(command_list[i]))
tester_process_list[i] = subprocess.Popen(command_list[i])
# Sleep
time.sleep(test_duration) time.sleep(test_duration)
tester_process.send_signal(signal.SIGINT)
# Stop
for i in range(i,len(tester_process_list)):
tester_process_list[i].send_signal(signal.SIGINT)
# Ok
error_count = 0 error_count = 0
except: except:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment