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
1
Merge Requests
1
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
Cédric Le Ninivin
erp5
Commits
b277c730
Commit
b277c730
authored
Sep 15, 2020
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test_result: fix pylint messages and enable coding style test
parent
19408915
Changes
21
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
203 additions
and
75 deletions
+203
-75
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.ERP5ScalabilityDistributor.py
...al_components/document.erp5.ERP5ScalabilityDistributor.py
+2
-3
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.ERP5ScalabilityDistributor.xml
...l_components/document.erp5.ERP5ScalabilityDistributor.xml
+42
-3
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestNode.py
...tTemplateItem/portal_components/document.erp5.TestNode.py
+0
-1
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestNode.xml
...TemplateItem/portal_components/document.erp5.TestNode.xml
+42
-3
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestSuite.py
...TemplateItem/portal_components/document.erp5.TestSuite.py
+0
-1
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestSuite.xml
...emplateItem/portal_components/document.erp5.TestSuite.xml
+42
-3
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.ScalabilityTestSuiteUtils.py
...al_components/extension.erp5.ScalabilityTestSuiteUtils.py
+9
-11
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.ScalabilityTestSuiteUtils.xml
...l_components/extension.erp5.ScalabilityTestSuiteUtils.xml
+42
-3
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.TestResults.py
...plateItem/portal_components/extension.erp5.TestResults.py
+3
-12
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.TestResults.xml
...lateItem/portal_components/extension.erp5.TestResults.xml
+1
-6
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/BenchmarkResult_completed.xml
...rtal_skins/erp5_test_result/BenchmarkResult_completed.xml
+1
-1
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TaskDistributorAlarm_optimize.py
...l_skins/erp5_test_result/TaskDistributorAlarm_optimize.py
+1
-2
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestResult_getDiff.py
...eItem/portal_skins/erp5_test_result/TestResult_getDiff.py
+0
-2
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestResult_getJsonScalabilityStats.py
...ns/erp5_test_result/TestResult_getJsonScalabilityStats.py
+0
-1
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestResult_getSummaryForRSS.py
...tal_skins/erp5_test_result/TestResult_getSummaryForRSS.py
+1
-1
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestSuiteModule_addTestSuite.py
...al_skins/erp5_test_result/TestSuiteModule_addTestSuite.py
+1
-1
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestSuite_checkParameterConsistency.py
...s/erp5_test_result/TestSuite_checkParameterConsistency.py
+13
-15
bt5/erp5_test_result/WorkflowTemplateItem/portal_workflow/test_node_workflow/scripts/checkConsistency.py
...l_workflow/test_node_workflow/scripts/checkConsistency.py
+1
-2
bt5/erp5_test_result/WorkflowTemplateItem/portal_workflow/test_suite_workflow/scripts/TestSuite_afterValidate.py
...ow/test_suite_workflow/scripts/TestSuite_afterValidate.py
+1
-1
bt5/erp5_test_result/WorkflowTemplateItem/portal_workflow/test_suite_workflow/scripts/checkConsistency.py
..._workflow/test_suite_workflow/scripts/checkConsistency.py
+1
-2
bt5/erp5_test_result/bt/skip_coding_style_test
bt5/erp5_test_result/bt/skip_coding_style_test
+0
-1
No files found.
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.ERP5ScalabilityDistributor.py
View file @
b277c730
...
@@ -33,7 +33,6 @@ from AccessControl import ClassSecurityInfo
...
@@ -33,7 +33,6 @@ from AccessControl import ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
from
Products.ERP5Type
import
Permissions
import
json
import
json
import
jinja2
import
jinja2
from
erp5.component.tool.TaskDistributionTool
import
TaskDistributionTool
class
ERP5ScalabilityDistributor
(
ERP5ProjectUnitTestDistributor
,
object
):
class
ERP5ScalabilityDistributor
(
ERP5ProjectUnitTestDistributor
,
object
):
security
=
ClassSecurityInfo
()
security
=
ClassSecurityInfo
()
...
@@ -270,10 +269,10 @@ class ERP5ScalabilityDistributor(ERP5ProjectUnitTestDistributor, object):
...
@@ -270,10 +269,10 @@ class ERP5ScalabilityDistributor(ERP5ProjectUnitTestDistributor, object):
if
current_container
==
my_value
:
if
current_container
==
my_value
:
return
True
return
True
elif
isinstance
(
current_container
,
dict
):
elif
isinstance
(
current_container
,
dict
):
for
k
,
v
in
current_container
.
items
():
for
k
,
v
in
current_container
.
items
():
if
str
(
my_value
)
in
str
(
k
):
if
str
(
my_value
)
in
str
(
k
):
return
True
return
True
if
_isInMyDictOrList
(
current_container
[
k
]
)
:
if
_isInMyDictOrList
(
v
)
:
return
True
return
True
elif
isinstance
(
current_container
,
list
):
elif
isinstance
(
current_container
,
list
):
for
sub_container
in
current_container
:
for
sub_container
in
current_container
:
...
...
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.ERP5ScalabilityDistributor.xml
View file @
b277c730
...
@@ -6,10 +6,22 @@
...
@@ -6,10 +6,22 @@
</pickle>
</pickle>
<pickle>
<pickle>
<dictionary>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<item>
<key>
<string>
default_reference
</string>
</key>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
ERP5ScalabilityDistributor
</string>
</value>
<value>
<string>
ERP5ScalabilityDistributor
</string>
</value>
</item>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<item>
<key>
<string>
id
</string>
</key>
<key>
<string>
id
</string>
</key>
<value>
<string>
document.erp5.ERP5ScalabilityDistributor
</string>
</value>
<value>
<string>
document.erp5.ERP5ScalabilityDistributor
</string>
</value>
...
@@ -24,6 +36,18 @@
...
@@ -24,6 +36,18 @@
<none/>
<none/>
</value>
</value>
</item>
</item>
<item>
<key>
<string>
text_content_error_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<item>
<key>
<string>
version
</string>
</key>
<key>
<string>
version
</string>
</key>
<value>
<string>
erp5
</string>
</value>
<value>
<string>
erp5
</string>
</value>
...
@@ -31,13 +55,28 @@
...
@@ -31,13 +55,28 @@
<item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<key>
<string>
workflow_history
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
</pickle>
...
@@ -50,7 +89,7 @@
...
@@ -50,7 +89,7 @@
<item>
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
...
@@ -59,7 +98,7 @@
...
@@ -59,7 +98,7 @@
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
</pickle>
...
...
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestNode.py
View file @
b277c730
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.XMLObject
import
XMLObject
from
DateTime
import
DateTime
from
DateTime
import
DateTime
from
zLOG
import
LOG
,
INFO
,
ERROR
from
AccessControl
import
ClassSecurityInfo
from
AccessControl
import
ClassSecurityInfo
from
Products.ERP5Type
import
Permissions
from
Products.ERP5Type
import
Permissions
...
...
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestNode.xml
View file @
b277c730
...
@@ -6,10 +6,22 @@
...
@@ -6,10 +6,22 @@
</pickle>
</pickle>
<pickle>
<pickle>
<dictionary>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<item>
<key>
<string>
default_reference
</string>
</key>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
TestNode
</string>
</value>
<value>
<string>
TestNode
</string>
</value>
</item>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<item>
<key>
<string>
id
</string>
</key>
<key>
<string>
id
</string>
</key>
<value>
<string>
document.erp5.TestNode
</string>
</value>
<value>
<string>
document.erp5.TestNode
</string>
</value>
...
@@ -24,6 +36,18 @@
...
@@ -24,6 +36,18 @@
<none/>
<none/>
</value>
</value>
</item>
</item>
<item>
<key>
<string>
text_content_error_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<item>
<key>
<string>
version
</string>
</key>
<key>
<string>
version
</string>
</key>
<value>
<string>
erp5
</string>
</value>
<value>
<string>
erp5
</string>
</value>
...
@@ -31,13 +55,28 @@
...
@@ -31,13 +55,28 @@
<item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<key>
<string>
workflow_history
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
</pickle>
...
@@ -50,7 +89,7 @@
...
@@ -50,7 +89,7 @@
<item>
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
...
@@ -59,7 +98,7 @@
...
@@ -59,7 +98,7 @@
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
</pickle>
...
...
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestSuite.py
View file @
b277c730
from
Products.ERP5Type.XMLObject
import
XMLObject
from
Products.ERP5Type.XMLObject
import
XMLObject
from
DateTime
import
DateTime
from
DateTime
import
DateTime
from
zLOG
import
LOG
,
INFO
,
ERROR
from
AccessControl
import
ClassSecurityInfo
from
AccessControl
import
ClassSecurityInfo
from
Acquisition
import
aq_base
from
Acquisition
import
aq_base
from
Products.ERP5Type
import
Permissions
from
Products.ERP5Type
import
Permissions
...
...
bt5/erp5_test_result/DocumentTemplateItem/portal_components/document.erp5.TestSuite.xml
View file @
b277c730
...
@@ -6,10 +6,22 @@
...
@@ -6,10 +6,22 @@
</pickle>
</pickle>
<pickle>
<pickle>
<dictionary>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<item>
<key>
<string>
default_reference
</string>
</key>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
TestSuite
</string>
</value>
<value>
<string>
TestSuite
</string>
</value>
</item>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<item>
<key>
<string>
id
</string>
</key>
<key>
<string>
id
</string>
</key>
<value>
<string>
document.erp5.TestSuite
</string>
</value>
<value>
<string>
document.erp5.TestSuite
</string>
</value>
...
@@ -24,6 +36,18 @@
...
@@ -24,6 +36,18 @@
<none/>
<none/>
</value>
</value>
</item>
</item>
<item>
<key>
<string>
text_content_error_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<item>
<key>
<string>
version
</string>
</key>
<key>
<string>
version
</string>
</key>
<value>
<string>
erp5
</string>
</value>
<value>
<string>
erp5
</string>
</value>
...
@@ -31,13 +55,28 @@
...
@@ -31,13 +55,28 @@
<item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<key>
<string>
workflow_history
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
</pickle>
...
@@ -50,7 +89,7 @@
...
@@ -50,7 +89,7 @@
<item>
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
...
@@ -59,7 +98,7 @@
...
@@ -59,7 +98,7 @@
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
</pickle>
...
...
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.ScalabilityTestSuiteUtils.py
View file @
b277c730
...
@@ -31,12 +31,12 @@ import json
...
@@ -31,12 +31,12 @@ import json
def
getGeneratedConfigurationList
(
self
,
*
args
,
**
kw
):
def
getGeneratedConfigurationList
(
self
,
*
args
,
**
kw
):
document_list
=
[]
document_list
=
[]
template
=
jinja2
.
Template
(
self
.
getClusterConfiguration
())
template
=
jinja2
.
Template
(
self
.
getClusterConfiguration
())
max
=
len
(
self
.
getGraphCoordinate
())
max
_
=
len
(
self
.
getGraphCoordinate
())
max_comp
=
100
max_comp
=
100
#max = self.getNumberConfiguration()
#max = self.getNumberConfiguration()
comp_list_view
=
[
"COMP-%i"
%
(
x
)
for
x
in
range
(
0
,
max_comp
)
]
comp_list_view
=
[
"COMP-%i"
%
(
x
)
for
x
in
range
(
0
,
max_comp
)
]
for
count
in
xrange
(
1
,
max
+
1
):
for
count
in
xrange
(
1
,
max
_
+
1
):
template_vars
=
{
"count"
:
count
,
"comp"
:
comp_list_view
}
template_vars
=
{
"count"
:
count
,
"comp"
:
comp_list_view
}
output_text
=
template
.
render
(
template_vars
)
output_text
=
template
.
render
(
template_vars
)
description
=
json
.
dumps
(
json
.
loads
(
output_text
),
sort_keys
=
True
,
indent
=
4
,
separators
=
(
','
,
': '
))
description
=
json
.
dumps
(
json
.
loads
(
output_text
),
sort_keys
=
True
,
indent
=
4
,
separators
=
(
','
,
': '
))
...
@@ -73,12 +73,12 @@ def generateConfigurationList(self, test_suite_title):
...
@@ -73,12 +73,12 @@ def generateConfigurationList(self, test_suite_title):
def
_isInMyDictOrListRec
(
my_container
,
my_value
):
def
_isInMyDictOrListRec
(
my_container
,
my_value
):
def
_isInMyDictOrList
(
current_container
):
def
_isInMyDictOrList
(
current_container
):
if
current_container
==
my_value
:
if
current_container
==
my_value
:
return
True
return
True
elif
type
(
current_container
)
==
type
({}
):
elif
isinstance
(
current_container
,
dict
):
for
k
,
v
in
current_container
.
item
s
():
for
v
in
current_container
.
value
s
():
if
_isInMyDictOrList
(
current_container
[
k
]
)
:
if
_isInMyDictOrList
(
v
)
:
return
True
return
True
elif
type
(
current_container
)
==
type
([]
):
elif
isinstance
(
current_container
,
list
):
for
sub_container
in
current_container
:
for
sub_container
in
current_container
:
if
_isInMyDictOrList
(
sub_container
)
:
if
_isInMyDictOrList
(
sub_container
)
:
return
True
return
True
...
@@ -97,8 +97,6 @@ def generateConfigurationList(self, test_suite_title):
...
@@ -97,8 +97,6 @@ def generateConfigurationList(self, test_suite_title):
lll
=
portal_task_distribution
.
searchFolder
(
title
=
test_suite
.
getSpecialiseTitle
())
lll
=
portal_task_distribution
.
searchFolder
(
title
=
test_suite
.
getSpecialiseTitle
())
distributor_uid
=
lll
[
0
].
getUid
()
distributor_uid
=
lll
[
0
].
getUid
()
cluster_configuration
=
test_suite
.
getClusterConfiguration
()
cluster_configuration
=
test_suite
.
getClusterConfiguration
()
cluster_constraint
=
test_suite
.
getClusterConstraint
()
#number_configuration = test_suite.getNumberConfiguration()
number_configuration
=
len
(
test_suite
.
getGraphCoordinate
())
number_configuration
=
len
(
test_suite
.
getGraphCoordinate
())
randomized_path
=
test_suite
.
getRandomizedPath
()
randomized_path
=
test_suite
.
getRandomizedPath
()
# Get testnodes available for this distributor
# Get testnodes available for this distributor
...
@@ -134,8 +132,8 @@ def generateConfigurationList(self, test_suite_title):
...
@@ -134,8 +132,8 @@ def generateConfigurationList(self, test_suite_title):
return_dict
[
'launchable'
]
=
True
return_dict
[
'launchable'
]
=
True
return_dict
[
'configuration_list'
]
=
configuration_list_json
return_dict
[
'configuration_list'
]
=
configuration_list_json
return_dict
[
'launcher_nodes_computer_guid'
]
=
launcher_nodes_computer_guid
return_dict
[
'launcher_nodes_computer_guid'
]
=
launcher_nodes_computer_guid
except
:
except
Exception
as
e
:
return_dict
[
'error_message'
]
=
'Bad json cluster_configuration
?'
return_dict
[
'error_message'
]
=
'Bad json cluster_configuration
. %s'
%
str
(
e
)
_unvalidateConfig
(
return_dict
)
_unvalidateConfig
(
return_dict
)
# If the number of available nodes is lower than
# If the number of available nodes is lower than
...
...
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.ScalabilityTestSuiteUtils.xml
View file @
b277c730
...
@@ -6,10 +6,22 @@
...
@@ -6,10 +6,22 @@
</pickle>
</pickle>
<pickle>
<pickle>
<dictionary>
<dictionary>
<item>
<key>
<string>
_recorded_property_dict
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<item>
<key>
<string>
default_reference
</string>
</key>
<key>
<string>
default_reference
</string>
</key>
<value>
<string>
ScalabilityTestSuiteUtils
</string>
</value>
<value>
<string>
ScalabilityTestSuiteUtils
</string>
</value>
</item>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<none/>
</value>
</item>
<item>
<item>
<key>
<string>
id
</string>
</key>
<key>
<string>
id
</string>
</key>
<value>
<string>
extension.erp5.ScalabilityTestSuiteUtils
</string>
</value>
<value>
<string>
extension.erp5.ScalabilityTestSuiteUtils
</string>
</value>
...
@@ -24,6 +36,18 @@
...
@@ -24,6 +36,18 @@
<none/>
<none/>
</value>
</value>
</item>
</item>
<item>
<key>
<string>
text_content_error_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<item>
<key>
<string>
version
</string>
</key>
<key>
<string>
version
</string>
</key>
<value>
<string>
erp5
</string>
</value>
<value>
<string>
erp5
</string>
</value>
...
@@ -31,13 +55,28 @@
...
@@ -31,13 +55,28 @@
<item>
<item>
<key>
<string>
workflow_history
</string>
</key>
<key>
<string>
workflow_history
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
I
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
data
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"3"
aka=
"AAAAAAAAAAM="
>
<pickle>
<pickle>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
<global
name=
"PersistentMapping"
module=
"Persistence.mapping"
/>
</pickle>
</pickle>
...
@@ -50,7 +89,7 @@
...
@@ -50,7 +89,7 @@
<item>
<item>
<key>
<string>
component_validation_workflow
</string>
</key>
<key>
<string>
component_validation_workflow
</string>
</key>
<value>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
M
=
</string>
</persistent>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAA
Q
=
</string>
</persistent>
</value>
</value>
</item>
</item>
</dictionary>
</dictionary>
...
@@ -59,7 +98,7 @@
...
@@ -59,7 +98,7 @@
</dictionary>
</dictionary>
</pickle>
</pickle>
</record>
</record>
<record
id=
"
3"
aka=
"AAAAAAAAAAM
="
>
<record
id=
"
4"
aka=
"AAAAAAAAAAQ
="
>
<pickle>
<pickle>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
<global
name=
"WorkflowHistoryList"
module=
"Products.ERP5Type.Workflow"
/>
</pickle>
</pickle>
...
...
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.TestResults.py
View file @
b277c730
...
@@ -2,8 +2,6 @@ import difflib
...
@@ -2,8 +2,6 @@ import difflib
import
zipfile
import
zipfile
import
os
import
os
import
re
import
re
import
sys
from
cStringIO
import
StringIO
from
zExceptions
import
Unauthorized
from
zExceptions
import
Unauthorized
separator1
=
'='
*
70
separator1
=
'='
*
70
...
@@ -107,7 +105,7 @@ def parseTestSuiteResults(file_handler):
...
@@ -107,7 +105,7 @@ def parseTestSuiteResults(file_handler):
if is_zelenium_test_suite:
if is_zelenium_test_suite:
# if this was a zelenium functional test, the output is completly
# if this was a zelenium functional test, the output is completly
# different
# different
junk
, title, summary, detail = stdout.split('-' * 79)
_
, title, summary, detail = stdout.split('-' * 79)
test_result_detail['stdout'] = summary
test_result_detail['stdout'] = summary
html_test_result = detail
html_test_result = detail
search = FTEST_PASS_FAIL_RE.search(title)
search = FTEST_PASS_FAIL_RE.search(title)
...
@@ -187,7 +185,6 @@ def TestResult_sendEmailNotification(self, mail_to=None, mail_from=None,
...
@@ -187,7 +185,6 @@ def TestResult_sendEmailNotification(self, mail_to=None, mail_from=None,
failed_test_case_list = []
failed_test_case_list = []
with_skips_test_case_list = []
with_skips_test_case_list = []
unknown_status_test_case_list = []
unknown_status_test_case_list = []
only_func_test = 1
for tcr in test_result.contentValues(portal_type='Test Result Line',
for tcr in test_result.contentValues(portal_type='Test Result Line',
sort_on='title'):
sort_on='title'):
if (tcr.getProperty('errors', 0) + tcr.getProperty('failures', 0)):
if (tcr.getProperty('errors', 0) + tcr.getProperty('failures', 0)):
...
@@ -197,12 +194,6 @@ def TestResult_sendEmailNotification(self, mail_to=None, mail_from=None,
...
@@ -197,12 +194,6 @@ def TestResult_sendEmailNotification(self, mail_to=None, mail_from=None,
unknown_status_test_case_list.append(tcr)
unknown_status_test_case_list.append(tcr)
if tcr.getProperty('skips'):
if tcr.getProperty('skips'):
with_skips_test_case_list.append(tcr)
with_skips_test_case_list.append(tcr)
if not tcr.getProperty('html_test_result'):
only_func_test = 0
# Don't send mail if we only run functional tests
#if only_func_test:
# return
p('Test Suite: %s' % test_result.getTitle())
p('Test Suite: %s' % test_result.getTitle())
p('Revision: %s' % test_result.getReference() or test_result.getIntIndex())
p('Revision: %s' % test_result.getReference() or test_result.getIntIndex())
...
@@ -262,8 +253,8 @@ def TestResult_sendEmailNotification(self, mail_to=None, mail_from=None,
...
@@ -262,8 +253,8 @@ def TestResult_sendEmailNotification(self, mail_to=None, mail_from=None,
for tcr in with_skips_test_case_list:
for tcr in with_skips_test_case_list:
p('
\
n
%-50s (%s skips)' % (tcr.getTitle(), tcr.getProperty('skips')))
p('
\
n
%-50s (%s skips)' % (tcr.getTitle(), tcr.getProperty('skips')))
for line in tcr.getProperty('stderr', '').splitlines():
for line in tcr.getProperty('stderr', '').splitlines():
if 'skipped ' in line:
if 'skipped ' in line:
p(' %s' % line)
p(' %s' % line)
p('')
p('')
return ('
\
n
'.join(mail_body),
return ('
\
n
'.join(mail_body),
...
...
bt5/erp5_test_result/ExtensionTemplateItem/portal_components/extension.erp5.TestResults.xml
View file @
b277c730
...
@@ -45,12 +45,7 @@
...
@@ -45,12 +45,7 @@
<item>
<item>
<key>
<string>
text_content_warning_message
</string>
</key>
<key>
<string>
text_content_warning_message
</string>
</key>
<value>
<value>
<tuple>
<tuple/>
<string>
W:265, 0: Bad indentation. Found 12 spaces, expected 10 (bad-indentation)
</string>
<string>
W:266, 0: Bad indentation. Found 16 spaces, expected 12 (bad-indentation)
</string>
<string>
W:110, 6: Unused variable \'junk\' (unused-variable)
</string>
<string>
W:190, 4: Unused variable \'only_func_test\' (unused-variable)
</string>
</tuple>
</value>
</value>
</item>
</item>
<item>
<item>
...
...
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/BenchmarkResult_completed.xml
View file @
b277c730
...
@@ -50,7 +50,7 @@
...
@@ -50,7 +50,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
_params
</string>
</key>
<key>
<string>
_params
</string>
</key>
<value>
<string>
result, error_message_list=
[]
</string>
</value>
<value>
<string>
result, error_message_list=
()
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
id
</string>
</key>
<key>
<string>
id
</string>
</key>
...
...
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TaskDistributorAlarm_optimize.py
View file @
b277c730
from
Products.ZSQLCatalog.SQLCatalog
import
Query
from
DateTime
import
DateTime
from
DateTime
import
DateTime
now
=
DateTime
()
now
=
DateTime
()
#Clean-up invalidated Test Nodes and
#Clean-up invalidated Test Nodes and
...
@@ -24,7 +23,7 @@ for test_node in list_node:
...
@@ -24,7 +23,7 @@ for test_node in list_node:
if
ping_date
<=
old_date
:
if
ping_date
<=
old_date
:
test_node
.
invalidate
()
test_node
.
invalidate
()
elif
validation_state
==
'invalidated'
:
elif
validation_state
==
'invalidated'
:
__traceback_info__
=
test_node
__traceback_info__
=
test_node
# pylint:disable=unused-variable
if
test_node
.
getSpecialise
():
if
test_node
.
getSpecialise
():
test_node
.
getSpecialiseValue
().
cleanupInvalidatedTestNode
(
test_node
)
test_node
.
getSpecialiseValue
().
cleanupInvalidatedTestNode
(
test_node
)
...
...
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestResult_getDiff.py
View file @
b277c730
...
@@ -18,8 +18,6 @@ if a.getIntIndex() > b.getIntIndex():
...
@@ -18,8 +18,6 @@ if a.getIntIndex() > b.getIntIndex():
b_title_dict
=
dict
((
line
.
getObject
().
getTitle
(),
line
.
id
)
for
line
\
b_title_dict
=
dict
((
line
.
getObject
().
getTitle
(),
line
.
id
)
for
line
\
in
b
.
searchFolder
(
portal_type
=
'Test Result Line'
))
in
b
.
searchFolder
(
portal_type
=
'Test Result Line'
))
not_in_b
=
{}
object_list
=
[]
object_list
=
[]
compared_prop_list
=
(
'all_tests'
,
'errors'
,
'failures'
,
'skips'
)
compared_prop_list
=
(
'all_tests'
,
'errors'
,
'failures'
,
'skips'
)
...
...
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestResult_getJsonScalabilityStats.py
View file @
b277c730
from
Products.PythonScripts.standard
import
Object
import
json
import
json
# Get result lines
# Get result lines
...
...
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestResult_getSummaryForRSS.py
View file @
b277c730
...
@@ -14,7 +14,7 @@ p('Revision: %s' % test_result.getReference() or test_result.getIntIndex())
...
@@ -14,7 +14,7 @@ p('Revision: %s' % test_result.getReference() or test_result.getIntIndex())
p
(
'Launch Date: %s'
%
test_result
.
getStartDate
())
p
(
'Launch Date: %s'
%
test_result
.
getStartDate
())
comment
=
test_result
.
getProperty
(
'comment'
)
comment
=
test_result
.
getProperty
(
'comment'
)
if
comment
:
if
comment
:
p
(
comment
)
p
(
comment
)
p
(
''
)
p
(
''
)
p
(
'All tests: %s, Failures: %s, Errors: %s, Skips: %s'
%
\
p
(
'All tests: %s, Failures: %s, Errors: %s, Skips: %s'
%
\
(
test_result
.
getProperty
(
'all_tests'
),
(
test_result
.
getProperty
(
'all_tests'
),
...
...
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestSuiteModule_addTestSuite.py
View file @
b277c730
...
@@ -15,4 +15,4 @@ test_suite = context.newContent(
...
@@ -15,4 +15,4 @@ test_suite = context.newContent(
)
)
if
batch_mode
:
if
batch_mode
:
return
test_suite
return
test_suite
bt5/erp5_test_result/SkinTemplateItem/portal_skins/erp5_test_result/TestSuite_checkParameterConsistency.py
View file @
b277c730
import
json
context
.
REQUEST
.
response
.
setHeader
(
'Access-Control-Allow-Origin'
,
'*'
)
context
.
REQUEST
.
response
.
setHeader
(
'Access-Control-Allow-Origin'
,
'*'
)
error
=
[]
error
=
[]
#We should verify if the project actually exists
#We should verify if the project actually exists
if
context
.
getTitle
()
is
None
:
if
context
.
getTitle
()
is
None
:
error
.
append
(
'ERROR: No project associated!'
)
error
.
append
(
'ERROR: No project associated!'
)
if
context
.
getTestSuite
()
is
None
:
if
context
.
getTestSuite
()
is
None
:
error
.
append
(
'ERROR: No test-suite associated!'
)
error
.
append
(
'ERROR: No test-suite associated!'
)
if
context
.
getTestSuiteTitle
()
is
None
:
if
context
.
getTestSuiteTitle
()
is
None
:
error
.
append
(
'ERROR: No test-suite-title associated!'
)
error
.
append
(
'ERROR: No test-suite-title associated!'
)
vcs_repository_list
=
context
.
objectValues
(
portal_type
=
"Test Suite Repository"
)
vcs_repository_list
=
context
.
objectValues
(
portal_type
=
"Test Suite Repository"
)
if
len
(
vcs_repository_list
)
==
0
:
if
len
(
vcs_repository_list
)
==
0
:
error
.
append
(
"No vcs_repository_list! (minimum 1)"
)
error
.
append
(
"No vcs_repository_list! (minimum 1)"
)
else
:
else
:
profile_count
=
0
profile_count
=
0
for
vcs_list
in
vcs_repository_list
:
for
vcs_list
in
vcs_repository_list
:
for
property_name
in
[
'git_url'
,
'buildout_section_id'
,
'branch'
]:
for
property_name
in
[
'git_url'
,
'buildout_section_id'
,
'branch'
]:
property_value
=
vcs_list
.
getProperty
(
property_name
)
property_value
=
vcs_list
.
getProperty
(
property_name
)
if
property_value
is
None
:
if
property_value
is
None
:
error
.
append
(
'ERROR: No '
+
property_name
+
'!'
)
error
.
append
(
'ERROR: No '
+
property_name
+
'!'
)
if
not
(
vcs_list
.
getProperty
(
'profile_path'
)
is
None
):
if
not
(
vcs_list
.
getProperty
(
'profile_path'
)
is
None
):
profile_count
+=
1
profile_count
+=
1
if
profile_count
==
0
:
if
profile_count
==
0
:
error
.
append
(
'ERROR: No profile_path in any vcs_repository! (minimum 1)'
)
error
.
append
(
'ERROR: No profile_path in any vcs_repository! (minimum 1)'
)
return
len
(
error
)
>
0
return
len
(
error
)
>
0
bt5/erp5_test_result/WorkflowTemplateItem/portal_workflow/test_node_workflow/scripts/checkConsistency.py
View file @
b277c730
object
=
state_change
[
'object'
]
state_change
[
'object'
].
Base_checkConsistency
()
object
.
Base_checkConsistency
()
bt5/erp5_test_result/WorkflowTemplateItem/portal_workflow/test_suite_workflow/scripts/TestSuite_afterValidate.py
View file @
b277c730
...
@@ -20,7 +20,7 @@ if test_suite.getReference() is None:
...
@@ -20,7 +20,7 @@ if test_suite.getReference() is None:
def
generateRandomString
(
size
):
def
generateRandomString
(
size
):
tab
=
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
tab
=
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
my_string
=
''
my_string
=
''
for
i
in
range
(
size
):
for
_
in
range
(
size
):
my_string
=
my_string
+
choice
(
tab
)
my_string
=
my_string
+
choice
(
tab
)
return
my_string
return
my_string
...
...
bt5/erp5_test_result/WorkflowTemplateItem/portal_workflow/test_suite_workflow/scripts/checkConsistency.py
View file @
b277c730
object
=
state_change
[
'object'
]
state_change
[
'object'
].
Base_checkConsistency
()
object
.
Base_checkConsistency
()
bt5/erp5_test_result/bt/skip_coding_style_test
deleted
100644 → 0
View file @
19408915
1
\ No newline at end of file
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