mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-19 14:04:17 +03:00
lvmdbustest.py: Denote failure if set_execution fails
This commit is contained in:
parent
0c51f369a4
commit
3e45285b40
@ -1298,6 +1298,7 @@ class TestDbusService(unittest.TestCase):
|
|||||||
self.assertTrue(tag in vg_proxy.Vg.Tags, "%s not in %s" %
|
self.assertTrue(tag in vg_proxy.Vg.Tags, "%s not in %s" %
|
||||||
(tag, str(vg_proxy.Vg.Tags)))
|
(tag, str(vg_proxy.Vg.Tags)))
|
||||||
|
|
||||||
|
|
||||||
class AggregateResults(object):
|
class AggregateResults(object):
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
@ -1307,6 +1308,9 @@ class AggregateResults(object):
|
|||||||
if not result.result.wasSuccessful():
|
if not result.result.wasSuccessful():
|
||||||
self.no_errors = False
|
self.no_errors = False
|
||||||
|
|
||||||
|
def register_fail(self):
|
||||||
|
self.no_errors = False
|
||||||
|
|
||||||
def exit_run(self):
|
def exit_run(self):
|
||||||
if self.no_errors:
|
if self.no_errors:
|
||||||
sys.exit(0)
|
sys.exit(0)
|
||||||
@ -1339,6 +1343,7 @@ if __name__ == '__main__':
|
|||||||
g_tmo = 15
|
g_tmo = 15
|
||||||
r.register_result(unittest.main(exit=False))
|
r.register_result(unittest.main(exit=False))
|
||||||
else:
|
else:
|
||||||
|
r.register_fail()
|
||||||
std_err_print("ERROR: Unable to dynamically configure "
|
std_err_print("ERROR: Unable to dynamically configure "
|
||||||
"service to use lvm shell!")
|
"service to use lvm shell!")
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user