Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
telecom
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Roque
telecom
Commits
bc2055b0
Commit
bc2055b0
authored
Oct 02, 2017
by
Roque Porchetto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
New test suite for scalability tests moved to new folder 'scalability_test'
parent
e68bee3a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
25 additions
and
78 deletions
+25
-78
scalability_test/__init__.py
scalability_test/__init__.py
+25
-0
scalability_test/examples/createPerson.py
scalability_test/examples/createPerson.py
+0
-0
scalability_test/examples/scalabilityUsers.py
scalability_test/examples/scalabilityUsers.py
+0
-0
tests/__init__.py
tests/__init__.py
+0
-78
No files found.
scalability_test/__init__.py
0 → 100644
View file @
bc2055b0
import
os.path
class
WendelinERP5_scalability
(
_ERP5
):
def
getTestList
(
self
):
return
[
'createPerson'
]
def
getTestPath
(
self
):
return
'examples/'
def
getUsersFilePath
(
self
):
return
'examples/scalabilityUsers'
def
getUserNumber
(
self
,
test_number
):
return
1
return
[
45
,
135
,
170
,
220
,
250
][
test_number
]
# Test duration in seconds
def
getTestDuration
(
self
,
test_number
):
return
60
*
10
def
getTestRepetition
(
self
,
test_number
):
return
1
return
3
tests
/examples/createPerson.py
→
scalability_test
/examples/createPerson.py
View file @
bc2055b0
File moved
tests
/examples/scalabilityUsers.py
→
scalability_test
/examples/scalabilityUsers.py
View file @
bc2055b0
File moved
tests/__init__.py
View file @
bc2055b0
...
...
@@ -24,83 +24,5 @@ class MasterWendelinERP5(ERP5TypeTestSuite):
return ['%s:%s' % (x.group(1), x.group(2))
\
for x in [component_re.match(y) for y in glob.glob(os.path.join(
BT5, '*', '*', '*', 'test.erp5.wendelin.test*.py'))]]
class _ERP5(ERP5TypeTestSuite):
realtime_output = False
enabled_product_list = ('CMFActivity', 'CMFCategory', 'ERP5', 'ERP5Catalog',
'ERP5eGovSecurity', 'ERP5Form',
'ERP5OOo', 'ERP5Security', 'ERP5SyncML', 'ERP5Type',
'ERP5VCS', 'ERP5Wizard', 'Formulator', 'ERP5Workflow',
'ERP5Configurator','HBTreeFolder2', 'MailTemplates',
'PortalTransforms', 'TimerService', 'ZLDAPConnection',
'ZLDAPMethods', 'ZMySQLDA', 'ZSQLCatalog', 'Zelenium')
def enableProducts(self):
product_set = set(self.enabled_product_list)
try:
dir_set = set(os.walk('Products').next()[1])
for product in dir_set - product_set:
os.unlink(os.path.join('Products', product))
product_set -= dir_set
except StopIteration:
os.mkdir('Products')
for product in product_set:
os.symlink(os.path.join('..', 'products', product),
os.path.join('Products', product))
def _getAllTestList(self):
test_list = []
path = sys.path[0]
component_re = re.compile("
.
*/
([
^/
]
+
)
/
TestTemplateItem
/
portal_components
"
"
/
test
\
.[
^
.]
+
\
.([
^
.]
+
).
py
$
")
for test_path in (
glob('%s/product/*/tests/test*.py' % path) +
glob('%s/bt5/*/TestTemplateItem/test*.py' % path) +
glob('%s/bt5/*/TestTemplateItem/portal_components/test.*.test*.py' % path)):
component_re_match = component_re.match(test_path)
if component_re_match is not None:
test_case = "
%
s
:
%
s
" % (component_re_match.group(1),
component_re_match.group(2))
else:
test_case = test_path.split(os.sep)[-1][:-3] # remove .py
product = test_path.split(os.sep)[-3]
# don't test 3rd party products
if product in ('PortalTransforms', 'MailTemplates', 'Zelenium'):
continue
# ERP5TioSafe is disabled for now because it requires external programs
# such as php and it has not been updated for Zope >= 2.12
if product == 'ERP5TioSafe':
continue
test_list.append(test_case)
return test_list
def update(self):
self.checkout('products', 'bt5')
self.enableProducts()
class WendelinERP5_scalability(_ERP5):
def getTestList(self):
return ['createPerson']
def getTestPath(self):
return 'examples/'
def getUsersFilePath(self):
return 'examples/scalabilityUsers'
def getUserNumber(self, test_number):
return 1
return [45, 135, 170, 220, 250][test_number]
# Test duration in seconds
def getTestDuration(self, test_number):
return 60*10
def getTestRepetition(self, test_number):
return 1
return 3
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment