Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Douglas
erp5
Commits
6b323964
Commit
6b323964
authored
Jun 11, 2012
by
Sebastien Robin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
redefine list of performance tests and some refactoring
parent
5ff45f02
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
14 deletions
+16
-14
tests/__init__.py
tests/__init__.py
+16
-14
No files found.
tests/__init__.py
View file @
6b323964
...
@@ -27,6 +27,18 @@ class _ERP5(ERP5TypeTestSuite):
...
@@ -27,6 +27,18 @@ class _ERP5(ERP5TypeTestSuite):
os
.
symlink
(
os
.
path
.
join
(
'..'
,
'products'
,
product
),
os
.
symlink
(
os
.
path
.
join
(
'..'
,
'products'
,
product
),
os
.
path
.
join
(
'Products'
,
product
))
os
.
path
.
join
(
'Products'
,
product
))
def
_getAllTestList
(
self
):
test_list
=
[]
for
test_path
in
glob
.
glob
(
'%s/product/*/tests/test*.py'
%
sys
.
path
[
0
])
+
\
glob
.
glob
(
'%s/bt5/*/TestTemplateItem/test*.py'
%
sys
.
path
[
0
]):
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
test_list
.
append
(
test_case
)
return
test_list
def
update
(
self
):
def
update
(
self
):
self
.
checkout
(
'products'
,
'bt5'
)
self
.
checkout
(
'products'
,
'bt5'
)
self
.
enableProducts
()
self
.
enableProducts
()
...
@@ -36,29 +48,19 @@ class PERF(_ERP5):
...
@@ -36,29 +48,19 @@ class PERF(_ERP5):
allow_restart
=
True
allow_restart
=
True
def
getTestList
(
self
):
def
getTestList
(
self
):
return
(
'testPerformance'
,)
*
3
return
[
x
for
x
in
self
.
_getAllTestList
()
if
x
.
find
(
'Performance'
)
>
0
]
def
update
(
self
):
self
.
checkout
(
'products'
,
'bt5/erp5_base'
,
'bt5/erp5_ui_test'
)
self
.
enableProducts
()
class
ERP5
(
_ERP5
):
class
ERP5
(
_ERP5
):
mysql_db_count
=
3
mysql_db_count
=
3
def
getTestList
(
self
):
def
getTestList
(
self
):
test_list
=
[]
test_list
=
[]
for
test_path
in
glob
.
glob
(
'%s/product/*/tests/test*.py'
%
sys
.
path
[
0
])
+
\
for
test_case
in
self
.
_getAllTestList
():
glob
.
glob
(
'%s/bt5/*/TestTemplateItem/test*.py'
%
sys
.
path
[
0
]):
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
# skip some tests
# skip some tests
if
test_case
.
startswith
(
'testLive'
)
or
test_case
.
startswith
(
'testVifib'
)
\
if
test_case
.
startswith
(
'testLive'
)
or
test_case
.
startswith
(
'testVifib'
)
\
or
test_case
.
startswith
(
'testFunctional'
)
\
or
test_case
.
startswith
(
'testFunctional'
)
\
or
test_case
in
(
'testPerformance'
,
'testSimulationPerformance1'
,
or
test_case
.
find
(
'Performance'
)
>
0
\
'testERP5LdapCatalog'
,
# XXX (Ivan), until LDAP server is available this test will alway fail
or
test_case
in
(
'testERP5LdapCatalog'
,
# XXX (Ivan), until LDAP server is available this test will alway fail
'testERP5eGov'
,
# it is not maintained any more
'testERP5eGov'
,
# it is not maintained any more
'testAccounting_l10n_fr_m9'
):
'testAccounting_l10n_fr_m9'
):
continue
continue
...
...
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