Improve logging about image testablity.
authorIgor Stoppa <igor.stoppa@intel.com>
Tue, 20 Jan 2015 10:10:03 +0000 (12:10 +0200)
committerZhuoX Li <zhuox.li@intel.com>
Wed, 21 Jan 2015 03:42:10 +0000 (11:42 +0800)
Log also when the image is supported.
In both cases (supported/unsupported), log also the name of the image.

Change-Id: I3fde2a5525078810f4c65a5f916e3145b1d127d7

job_test_build.py

index 558c495..5d53f46 100755 (executable)
@@ -145,7 +145,9 @@ def image_supported(image):
         logging.info("Verifying testability of image {0}.".format(image))
         subprocess.check_output(command)
     except subprocess.CalledProcessError:
+        logging.info("Image {0} not supported by the tester.".format(image))
         return False
+    logging.info("Image {0} supported by the tester.".format(image))
     return True
 
 def propagate_results(fields, image):
@@ -195,7 +197,6 @@ def main():
         return 0
 
     if not image_supported(file_name):
-        logging.info("Image not supported by the tester.")
         fields["test_result"] = "IMAGE_NOT_SUPPORTED"
         propagate_results(image=file_name, fields=fields)
         return 0