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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Xavier Thompson
erp5
Commits
31a4cf96
Commit
31a4cf96
authored
May 19, 2020
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
testnode: pylint fixes in test
parent
2d6cc102
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
9 deletions
+8
-9
erp5/tests/testERP5TestNode.py
erp5/tests/testERP5TestNode.py
+8
-9
No files found.
erp5/tests/testERP5TestNode.py
View file @
31a4cf96
...
@@ -331,7 +331,7 @@ shared = true
...
@@ -331,7 +331,7 @@ shared = true
It could happen that the branch is changed for a repository. Testnode must
It could happen that the branch is changed for a repository. Testnode must
be able to reset correctly the branch
be able to reset correctly the branch
"""
"""
commit_dict
=
self
.
generateTestRepositoryList
(
add_third_repository
=
True
)
self
.
generateTestRepositoryList
(
add_third_repository
=
True
)
test_node
=
self
.
getTestNode
()
test_node
=
self
.
getTestNode
()
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
self
.
updateNodeTestSuiteData
(
node_test_suite
,
add_third_repository
=
True
)
self
.
updateNodeTestSuiteData
(
node_test_suite
,
add_third_repository
=
True
)
...
@@ -376,7 +376,7 @@ shared = true
...
@@ -376,7 +376,7 @@ shared = true
change of username and password). testnode must be able to erase and clone
change of username and password). testnode must be able to erase and clone
again the repository
again the repository
"""
"""
commit_dict
=
self
.
generateTestRepositoryList
(
add_third_repository
=
True
)
self
.
generateTestRepositoryList
(
add_third_repository
=
True
)
test_node
=
self
.
getTestNode
()
test_node
=
self
.
getTestNode
()
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
...
@@ -415,7 +415,7 @@ shared = true
...
@@ -415,7 +415,7 @@ shared = true
Testnode must be able reset the repository to make sure we have no failures
Testnode must be able reset the repository to make sure we have no failures
when updating repository
when updating repository
"""
"""
commit_dict
=
self
.
generateTestRepositoryList
(
add_third_repository
=
True
)
self
.
generateTestRepositoryList
(
add_third_repository
=
True
)
test_node
=
self
.
getTestNode
()
test_node
=
self
.
getTestNode
()
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
...
@@ -443,7 +443,7 @@ shared = true
...
@@ -443,7 +443,7 @@ shared = true
crendentials), the testnode should not block forever and should work on
crendentials), the testnode should not block forever and should work on
other test suites. This method should be able to run
other test suites. This method should be able to run
"""
"""
commit_dict
=
self
.
generateTestRepositoryList
()
self
.
generateTestRepositoryList
()
test_node
=
self
.
getTestNode
()
test_node
=
self
.
getTestNode
()
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
self
.
updateNodeTestSuiteData
(
node_test_suite
,
add_broken_repository
=
True
)
self
.
updateNodeTestSuiteData
(
node_test_suite
,
add_broken_repository
=
True
)
...
@@ -460,7 +460,7 @@ shared = true
...
@@ -460,7 +460,7 @@ shared = true
repository's index, then we call updateRevisionList to check that it can
repository's index, then we call updateRevisionList to check that it can
recover from this corruption.
recover from this corruption.
"""
"""
commit_dict
=
self
.
generateTestRepositoryList
()
self
.
generateTestRepositoryList
()
test_node
=
self
.
getTestNode
()
test_node
=
self
.
getTestNode
()
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
...
@@ -539,7 +539,7 @@ shared = true
...
@@ -539,7 +539,7 @@ shared = true
test_node
=
self
.
getTestNode
()
test_node
=
self
.
getTestNode
()
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
node_test_suite
=
test_node
.
getNodeTestSuite
(
'foo'
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
self
.
updateNodeTestSuiteData
(
node_test_suite
)
rev_list
=
self
.
getAndUpdateFullRevisionList
(
test_node
,
node_test_suite
)
self
.
getAndUpdateFullRevisionList
(
test_node
,
node_test_suite
)
def
getRepInfo
(
count
=
0
,
hash
=
0
):
def
getRepInfo
(
count
=
0
,
hash
=
0
):
assert
count
or
hash
assert
count
or
hash
info_list
=
[]
info_list
=
[]
...
@@ -926,7 +926,6 @@ shared = true
...
@@ -926,7 +926,6 @@ shared = true
return
"Certificate"
return
"Certificate"
def
patch_getSlaposUrl
(
self
,
*
args
,
**
kw
):
def
patch_getSlaposUrl
(
self
,
*
args
,
**
kw
):
return
"http://Foo"
return
"http://Foo"
return
"Certificate"
def
patch_getSlaposHateoasUrl
(
self
,
*
args
,
**
kw
):
def
patch_getSlaposHateoasUrl
(
self
,
*
args
,
**
kw
):
return
"http://Foo"
return
"http://Foo"
def
patch_generateConfiguration
(
self
,
*
args
,
**
kw
):
def
patch_generateConfiguration
(
self
,
*
args
,
**
kw
):
...
@@ -961,7 +960,7 @@ shared = true
...
@@ -961,7 +960,7 @@ shared = true
test_node
.
node_test_suite_dict
test_node
.
node_test_suite_dict
rand_part_set
=
set
()
rand_part_set
=
set
()
self
.
assertEqual
(
2
,
len
(
test_node
.
node_test_suite_dict
))
self
.
assertEqual
(
2
,
len
(
test_node
.
node_test_suite_dict
))
for
ref
,
suite
in
test_node
.
node_test_suite_dict
.
item
s
():
for
suite
in
test_node
.
node_test_suite_dict
.
value
s
():
self
.
assertTrue
(
'var/log/testnode/%s'
%
suite
.
reference
in
\
self
.
assertTrue
(
'var/log/testnode/%s'
%
suite
.
reference
in
\
suite
.
suite_log_path
,
suite
.
suite_log_path
,
"Incorrect suite log path : %r"
%
suite
.
suite_log_path
)
"Incorrect suite log path : %r"
%
suite
.
suite_log_path
)
...
@@ -1122,7 +1121,7 @@ shared = true
...
@@ -1122,7 +1121,7 @@ shared = true
self
.
assertRaises
(
SubprocessError
,
callPrepareSlapOS
)
self
.
assertRaises
(
SubprocessError
,
callPrepareSlapOS
)
self
.
assertEqual
(
node_test_suite
.
retry_software_count
,
0
)
self
.
assertEqual
(
node_test_suite
.
retry_software_count
,
0
)
for
x
in
range
(
11
):
for
_
in
range
(
11
):
callRaisingPrepareSlapos
()
callRaisingPrepareSlapos
()
self
.
assertEqual
(
len
(
init_call_kw_list
),
11
)
self
.
assertEqual
(
len
(
init_call_kw_list
),
11
)
self
.
assertEqual
(
init_call_kw_list
[
-
1
][
'reset_software'
],
False
)
self
.
assertEqual
(
init_call_kw_list
[
-
1
][
'reset_software'
],
False
)
...
...
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