From ba16cd907152d5b02be95bf7e0429738275f7720 Mon Sep 17 00:00:00 2001 From: Ryan Hitchman Date: Thu, 1 Mar 2018 23:29:44 -0800 Subject: [PATCH] Make sh2ju use awk instead of bc. awk is available in all of our test runners (as part of busybox or debian base packages), bc is not. --- third_party/forked/shell2junit/sh2ju.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/third_party/forked/shell2junit/sh2ju.sh b/third_party/forked/shell2junit/sh2ju.sh index f5f7ec4aa93..e461475366a 100755 --- a/third_party/forked/shell2junit/sh2ju.sh +++ b/third_party/forked/shell2junit/sh2ju.sh @@ -130,8 +130,8 @@ function juLog() { # calculate vars asserts=$(($asserts+1)) errors=$(($errors+$err)) - time=`echo "${end} - ${ini}" | bc -l` - total=`echo "${total} + ${time}" | bc -l` + time=`echo "${end} ${ini}" | awk '{print $1 - $2}'` + total=`echo "${total} ${time}" | awk '{print $1 + $2}'` # write the junit xml report ## failure tag