From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Campbell Subject: [PATCH OSSTEST v2 2/3] standalone: Check job status at end of run-job. Date: Fri, 2 Oct 2015 13:05:48 +0100 Message-ID: <1443787549-7467-2-git-send-email-ian.campbell@citrix.com> References: <1443787531.11707.80.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1443787531.11707.80.camel@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: ian.jackson@eu.citrix.com, xen-devel@lists.xen.org Cc: Ian Campbell List-Id: xen-devel@lists.xenproject.org Check if the job passed and if not (so status is fail, broken, running etc) then return an error. This is convenient for scripting. Signed-off-by: Ian Campbell Acked-by: Ian Jackson --- standalone | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/standalone b/standalone index b362b38..e4c16d7 100755 --- a/standalone +++ b/standalone @@ -308,6 +308,11 @@ case $op in OSSTEST_HOST_REUSE=$reuse \ OSSTEST_SIMULATE=$dryrun \ with_logging logs/$flight/$job.log ./sg-run-job $job + + status=`job_status $flight $job` + echo "$flight.$job status = $status" >&2 + if [ "x$status" != xpass ] ; then exit 1; fi + ;; run-test) need_flight; need_host -- 2.5.3