Commit 5e9050d6 authored by Benjamin Blanc's avatar Benjamin Blanc

scalability: correct warming up procedure

parent 2c627797
...@@ -300,9 +300,7 @@ class ScalabilityLauncher(object): ...@@ -300,9 +300,7 @@ class ScalabilityLauncher(object):
# Do not run a test while there are pending activities # Do not run a test while there are pending activities
waitFor0PendingActivities(self.__argumentNamespace.erp5_url, self.log) waitFor0PendingActivities(self.__argumentNamespace.erp5_url, self.log)
# Get the number of documents present before running the test. previous_document_number=0
previous_document_number = getCreatedDocumentNumberFromERP5(self.__argumentNamespace.erp5_url, self.log)
self.log("previous_document_number: %d" %previous_document_number)
self.log("Test Case %s is running..." %(current_test.title)) self.log("Test Case %s is running..." %(current_test.title))
try: try:
...@@ -319,7 +317,7 @@ class ScalabilityLauncher(object): ...@@ -319,7 +317,7 @@ class ScalabilityLauncher(object):
self.log("user_number: %s" %str(user_number)) self.log("user_number: %s" %str(user_number))
# WARMING UP # WARMING UP
self.log("Warming up run.. for 60s") self.log("Warming up run.. for 180s")
# Generate commands to run # Generate commands to run
command_list = [] command_list = []
user_index = 0 user_index = 0
...@@ -344,12 +342,20 @@ class ScalabilityLauncher(object): ...@@ -344,12 +342,20 @@ class ScalabilityLauncher(object):
self.log("command: %s" %str(command)) self.log("command: %s" %str(command))
tester_process_list.append(subprocess.Popen(command)) tester_process_list.append(subprocess.Popen(command))
# Sleep # Sleep
time.sleep(60) time.sleep(180)
# Stop # Stop
for tester_process in tester_process_list: for tester_process in tester_process_list:
tester_process.send_signal(signal.SIGINT) tester_process.send_signal(signal.SIGINT)
self.log("%s signal send to tester" %str(signal.SIGINT))
# /WARMING UP # /WARMING UP
# Wait for 0 activities
waitFor0PendingActivities(self.__argumentNamespace.erp5_url, self.log)
# Get the number of documents present before running the test.
previous_document_number = getCreatedDocumentNumberFromERP5(self.__argumentNamespace.erp5_url, self.log)
self.log("previous_document_number: %d" %previous_document_number)
self.log("test_duration: %ss" %str(test_duration)) self.log("test_duration: %ss" %str(test_duration))
# Generate commands to run # Generate commands to run
...@@ -383,6 +389,7 @@ class ScalabilityLauncher(object): ...@@ -383,6 +389,7 @@ class ScalabilityLauncher(object):
# Stop # Stop
for tester_process in tester_process_list: for tester_process in tester_process_list:
tester_process.send_signal(signal.SIGINT) tester_process.send_signal(signal.SIGINT)
self.log("%s signal send to tester" %str(signal.SIGINT))
# Ok # Ok
error_count = 0 error_count = 0
......
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