Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
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
Klaus Wölfel
slapos.core
Commits
d433eecf
Commit
d433eecf
authored
Aug 10, 2011
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Kill supervisord always.
parent
de598443
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
slapos/tests/slapgrid.py
slapos/tests/slapgrid.py
+9
-9
No files found.
slapos/tests/slapgrid.py
View file @
d433eecf
...
@@ -36,6 +36,15 @@ class BasicMixin:
...
@@ -36,6 +36,15 @@ class BasicMixin:
self
.
buildout
)
self
.
buildout
)
def
tearDown
(
self
):
def
tearDown
(
self
):
# XXX: Hardcoded pid, as it is not configurable in slapos
svc
=
os
.
path
.
join
(
self
.
instance_root
,
'var'
,
'run'
,
'supervisord.pid'
)
if
os
.
path
.
exists
(
svc
):
try
:
pid
=
int
(
open
(
svc
).
read
().
strip
())
except
ValueError
:
pass
else
:
os
.
kill
(
pid
,
signal
.
SIGTERM
)
shutil
.
rmtree
(
self
.
_tempdir
,
True
)
shutil
.
rmtree
(
self
.
_tempdir
,
True
)
class
TestBasicSlapgridCP
(
BasicMixin
,
unittest
.
TestCase
):
class
TestBasicSlapgridCP
(
BasicMixin
,
unittest
.
TestCase
):
...
@@ -76,15 +85,6 @@ class MasterMixin(BasicMixin):
...
@@ -76,15 +85,6 @@ class MasterMixin(BasicMixin):
def
tearDown
(
self
):
def
tearDown
(
self
):
self
.
_unpatchHttplib
()
self
.
_unpatchHttplib
()
# XXX: Hardcoded pid, as it is not configurable in slapos
svc
=
os
.
path
.
join
(
self
.
instance_root
,
'var'
,
'run'
,
'supervisord.pid'
)
if
os
.
path
.
exists
(
svc
):
try
:
pid
=
int
(
open
(
svc
).
read
().
strip
())
except
ValueError
:
pass
else
:
os
.
kill
(
pid
,
signal
.
SIGTERM
)
BasicMixin
.
tearDown
(
self
)
BasicMixin
.
tearDown
(
self
)
class
TestSlapgridCPWithMaster
(
MasterMixin
,
unittest
.
TestCase
):
class
TestSlapgridCPWithMaster
(
MasterMixin
,
unittest
.
TestCase
):
...
...
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