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
Labels
Merge Requests
138
Merge Requests
138
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
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
6b7b86fe
Commit
6b7b86fe
authored
Jul 09, 2013
by
Benjamin Blanc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
util: testnode: use dummy slapos answer with signal for getting instance state
parent
f3e17cc8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
3 deletions
+17
-3
erp5/util/testnode/ScalabilityTestRunner.py
erp5/util/testnode/ScalabilityTestRunner.py
+17
-3
No files found.
erp5/util/testnode/ScalabilityTestRunner.py
View file @
6b7b86fe
...
...
@@ -68,6 +68,7 @@ class ScalabilityTestRunner():
self
.
authorize_request
=
False
# Used to simulate SlapOS answer (used as a queue)
self
.
last_slapos_answer
=
[]
self
.
last_slapos_answer_request
=
[]
def
_prepareSlapOS
(
self
,
software_path
,
computer_guid
,
create_partition
=
0
):
# create_partition is kept for compatibility
...
...
@@ -168,6 +169,15 @@ late a SlapOS (positive) answer." %(str(os.getpid()),str(os.getpid()),))
# TODO : implement -> communication with SlapOS master
# this simulate a SlapOS answer
return
self
.
simulateSlapOSAnswer
()
def
isInstanceReady
(
self
,
instance_title
):
"""
Return true if the specified instance is ready.
This method should communicates with SlapOS Master.
"""
# TODO : implement -> communication with SlapOS master
# this simulate a SlapOS answer
return
self
.
simulateSlapOSAnswer
()
def
remainSoftwareToInstall
(
self
):
"""
...
...
@@ -304,9 +314,13 @@ late a SlapOS (positive) answer." %(str(os.getpid()),str(os.getpid()),))
self
.
_updateInstanceXML
(
self
.
reachable_profile
,
configuration
,
self
.
instance_title
,
node_test_suite
.
test_result
,
node_test_suite
.
test_suite
)
# Wait for ready status from slapos
self
.
log
(
"Wait for instance ready to test. Sleep for 300s."
)
time
.
sleep
(
300
)
self
.
log
(
"300s elapsed."
)
self
.
log
(
"Wait for instance ready to test.."
)
self
.
log
(
"Master testnode is waiting
\
do (kill -10 %s) to continue..."
,
str
(
os
.
getpid
()))
while
(
not
self
.
isSoftwareReleaseReady
(
self
.
instance_title
)):
time
.
sleep
(
5
)
pass
self
.
log
(
"Answer received."
)
# Start only the current test
exclude_list
=
[
x
for
x
in
test_list
if
x
!=
test_list
[
count
]]
...
...
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