From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Campbell Subject: [PATCH OSSTEST 3/5] standalone: Check job status at end of run-job. Date: Mon, 5 Oct 2015 15:35:06 +0100 Message-ID: <1444055708-15836-3-git-send-email-ian.campbell@citrix.com> References: <1444055694.5302.9.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1444055694.5302.9.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 ae70c43..3408d24 100755 --- a/standalone +++ b/standalone @@ -301,6 +301,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