From: Ondrej Lichtner <olichtne(a)redhat.com>
In case the Job was expected to fail, the passed attribute should
reflect this.
Signed-off-by: Ondrej Lichtner <olichtne(a)redhat.com>
---
lnst/Controller/Job.py | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/lnst/Controller/Job.py b/lnst/Controller/Job.py
index 96cf045..1026938 100644
--- a/lnst/Controller/Job.py
+++ b/lnst/Controller/Job.py
@@ -88,10 +88,13 @@ class Job(object):
def passed(self):
"""Indicates whether or not the Job passed
+ The return value is True or False based on if the Job was expected to
+ pass or fail.
+
Type: Boolean
"""
try:
- return self._res["passed"]
+ return self._res["passed"] == self._expect
except:
return False
--
2.16.1