Commit 630ccfc1 authored by Arnaud Fontaine's avatar Arnaud Fontaine

Fix whitespaces and lines over 80 characters


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk/utils@44766 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent dfc31234
......@@ -10,16 +10,18 @@ def benchmarkAddPerson(result_dict):
Benchmark adding a person
"""
# Create a browser instance
browser = Browser('http://localhost:18080/', 'erp5', username='zope', password='zope')
browser = Browser('http://localhost:18080/', 'erp5',
username='zope', password='zope')
# Open ERP5 homepage
# Open ERP5 homepage
browser.open()
# Go to Persons module (person_module)
browser.mainForm.submitSelectModule(label='Persons')
# Create a new person and record the time elapsed in seconds
result_dict.setdefault('Create new person', []).append(browser.mainForm.timeSubmitNewInSecond())
# Create a new person and record the time elapsed in seconds
result_dict.setdefault('Create new person', []).append(
browser.mainForm.timeSubmitNewInSecond())
# Check whether it has been successfully created
assert browser.getTransitionMessage() == 'Object created.'
......@@ -29,20 +31,22 @@ def benchmarkAddPerson(result_dict):
browser.mainForm.getControl(name='field_my_last_name').value = 'Bar'
# Submit the changes, record the time elapsed in seconds
result_dict.setdefault('Save', []).append(browser.mainForm.timeSubmitSaveInSecond())
result_dict.setdefault('Save', []).append(
browser.mainForm.timeSubmitSaveInSecond())
# Check whether the changes have been successfully updated
assert browser.getTransitionMessage() == 'Data updated.'
# Validate the person and record confirmation
browser.mainForm.submitSelectWorkflow(label='Validate')
result_dict.setdefault('Validate', []).append(browser.mainForm.timeSubmitDialogConfirmInSecond())
result_dict.setdefault('Validate', []).append(
browser.mainForm.timeSubmitDialogConfirmInSecond())
# Check whether it has been successfully validated
assert browser.getTransitionMessage() == 'Status changed.'
if __name__ == '__main__':
# Run benchmarkAddPerson ITERATION times and compute the average time it
# Run benchmarkAddPerson ITERATION times and compute the average time it
# took for each operation
result_dict = {}
counter = 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