Skip to contentSkip to conversation

KVM test: Fix bug in physical_resources_check

PATCH New Lucas Meneghel Rodrigues 1 participant 1 message Jul 14, 2011 KVM

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 KVM test: Fix bug in physical_resources_check

In r5451, several changes to the test were made, but a very simple one was forgotten: Change the check made in the end of the test to verify whether the test has passed or fail. n_fail is now a list of failures, so we need to test whether it is an empty list or not.

---
 client/tests/kvm/tests/physical_resources_check.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
client/tests/kvm/tests/physical_resources_check.py +1 -1
index 9691d9e..4e83814 100644
@@ -173,7 +173,7 @@ def run_physical_resources_check(test, params, env):
                            catch_serial_cmd)
     n_fail.extend(f_fail)
 
-    if n_fail != 0:
+    if n_fail:
         session.close()
         raise error.TestFail("Physical resources check test "
                              "reported %s failures:\n%s" %
Signature · 1 line
1.7.6