[autotest] Record re-imager job status correctly
Apparently, giving the wapper job a name in the START line, but not the END line
makes the parser barf when it tries to parse the END XXXX line in the status log:
START ----- Wrapper Job
GOOD ----- Inner Job
END GOOD ----- -----
is bad.
START ----- Wrapper Job
GOOD ----- Inner Job
END GOOD ----- Wrapper Job
is good!
BUG=chromium-os:25669
TEST=dynamic_suite_unittest.py
TEST=./server/autoserv test_suites/dev_harness
STATUS=Fixed
Change-Id: I64a0d9983d70a294035f6da2e4e14b9756c0e62e
Reviewed-on: https://gerrit.chromium.org/gerrit/15125
Tested-by: Chris Masone <cmasone@chromium.org>
Reviewed-by: Chris Sosa <sosa@chromium.org>
Commit-Ready: Chris Masone <cmasone@chromium.org>
diff --git a/server/cros/dynamic_suite.py b/server/cros/dynamic_suite.py
index e14054d..76d0605 100644
--- a/server/cros/dynamic_suite.py
+++ b/server/cros/dynamic_suite.py
@@ -80,7 +80,8 @@
record(status, subdir, name, reason)
@return True if all reimaging jobs succeed, false otherwise.
"""
- record('START', None, 'try new image')
+ wrapper_job_name = 'try new image'
+ record('START', None, wrapper_job_name)
self._ensure_version_label(VERSION_PREFIX+name)
canary = self._schedule_reimage_job(name, num, board)
logging.debug('Created re-imaging job: %d', canary.id)
@@ -94,7 +95,7 @@
if canary.result is True:
self._report_results(canary, record)
- record('END GOOD', None, None)
+ record('END GOOD', None, wrapper_job_name)
return True
if canary.result is None:
@@ -102,7 +103,7 @@
else: # canary.result is False
self._report_results(canary, record)
- record('END FAIL', None, None)
+ record('END FAIL', None, wrapper_job_name)
return False