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
1
Issues
1
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
Roque
erp5
Commits
4cf2bb01
Commit
4cf2bb01
authored
Jun 17, 2013
by
Benjamin Blanc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change SIGINT to SIGTERM signal to simulate SlapOS answers
parent
8a18779d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
erp5/util/testnode/ScalabilityTestRunner.py
erp5/util/testnode/ScalabilityTestRunner.py
+5
-4
No files found.
erp5/util/testnode/ScalabilityTestRunner.py
View file @
4cf2bb01
...
@@ -100,12 +100,13 @@ class ScalabilityTestRunner():
...
@@ -100,12 +100,13 @@ class ScalabilityTestRunner():
self
.
testnode
.
log
(
"Dummy SlapOS Master answer received."
)
self
.
testnode
.
log
(
"Dummy SlapOS Master answer received."
)
self
.
last_slapos_answer
.
append
(
True
)
self
.
last_slapos_answer
.
append
(
True
)
def
_prepareDummySlapOSAnswer
(
self
):
def
_prepareDummySlapOSAnswer
(
self
):
print
"Dummy slapOS answer enabled, press crtl+c to simulate SlapOS (positive) answer."
print
"Dummy slapOS answer enabled, send signal to %s (=PID) to simu
\
signal
.
signal
(
signal
.
SIGINT
,
self
.
_getSignal
)
late a SlapOS (positive) answer."
%
(
str
(
os
.
getpid
()),)
signal
.
signal
(
signal
.
SIGTERM
,
self
.
_getSignal
)
def
_comeBackFromDummySlapOS
(
self
):
def
_comeBackFromDummySlapOS
(
self
):
print
"Dummy slapOS answer disabled
, don't press crtl+c anymore.
"
print
"Dummy slapOS answer disabled"
# use SIG_USR (kill)
# use SIG_USR (kill)
signal
.
signal
(
signal
.
SIG
INT
,
signal
.
SIG_DFL
)
signal
.
signal
(
signal
.
SIG
TERM
,
signal
.
SIG_DFL
)
def
simulateSlapOSAnswer
(
self
):
def
simulateSlapOSAnswer
(
self
):
if
len
(
self
.
last_slapos_answer
)
==
0
:
if
len
(
self
.
last_slapos_answer
)
==
0
:
return
False
return
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