tests/{ctrl,vty}_test_runner.py: raise an exception if proc's rc != 0
Change-Id: I5fa3477979d41aef7b22464a925941ed0f115193 Depends: osmo-python-tests.git I1e11fcb6c5a587c27fc00920b6e157862d972fd9 Related: OS#5665
This commit is contained in:
parent
8798689f3b
commit
2a6954b3ae
|
@ -63,7 +63,9 @@ class TestCtrlBase(unittest.TestCase):
|
|||
|
||||
def tearDown(self):
|
||||
self.disconnect()
|
||||
osmoutil.end_proc(self.proc)
|
||||
rc = osmoutil.end_proc(self.proc)
|
||||
if rc is not None and rc != 0:
|
||||
raise Exception("Process returned %d" % rc)
|
||||
|
||||
def disconnect(self):
|
||||
if not (self.sock is None):
|
||||
|
|
|
@ -65,7 +65,9 @@ class TestVTYBase(unittest.TestCase):
|
|||
if self.vty:
|
||||
self.vty._close_socket()
|
||||
self.vty = None
|
||||
osmoutil.end_proc(self.proc)
|
||||
rc = osmoutil.end_proc(self.proc)
|
||||
if rc is not None and rc != 0:
|
||||
raise Exception("Process returned %d" % rc)
|
||||
|
||||
|
||||
class TestVTYGenericBSC(TestVTYBase):
|
||||
|
|
Loading…
Reference in New Issue