[KVM-AUTOTEST PATCH] KVM test: kvm.py: add exception class name to failure message

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This will result in more informative messages, e.g.:

Test failed: FileTransferConnectError: Could not connect to server

instead of

Test failed: Could not connect to server

Signed-off-by: Michael Goldish <mgoldish@xxxxxxxxxx>
---
 client/tests/kvm/kvm.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/client/tests/kvm/kvm.py b/client/tests/kvm/kvm.py
index 0799cff..9da4c33 100644
--- a/client/tests/kvm/kvm.py
+++ b/client/tests/kvm/kvm.py
@@ -75,7 +75,8 @@ class kvm(test.test):
                     test_passed = True
 
                 except Exception, e:
-                    logging.error("Test failed: %s", e)
+                    logging.error("Test failed: %s: %s",
+                                  e.__class__.__name__, e)
                     try:
                         kvm_preprocessing.postprocess_on_error(
                             self, params, env)
-- 
1.5.4.1

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux