From cc2c3b41b86d1dd8d23685c34be030f2607ed11d Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Thu, 30 Apr 2020 11:40:42 +0200 Subject: [PATCH] ci: fix reporting the number of unexpected/flakes `wc -l $file` returns the number of lines and the filename. Fixes: b8c66aeb934 ("ci: Clean up some excessive use of pipes in dEQP results processing.") Signed-off-by: Samuel Pitoiset Reviewed-by: Andres Gomez Reviewed-by: Eric Anholt Part-of: --- .gitlab-ci/deqp-runner.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci/deqp-runner.sh b/.gitlab-ci/deqp-runner.sh index d4de8f74baf..48d95b2bedd 100755 --- a/.gitlab-ci/deqp-runner.sh +++ b/.gitlab-ci/deqp-runner.sh @@ -259,7 +259,7 @@ if [ $DEQP_EXITCODE -ne 0 ]; then cat $UNEXPECTED_RESULTSFILE.txt fi - count=`wc -l $UNEXPECTED_RESULTSFILE.txt` + count=`cat $UNEXPECTED_RESULTSFILE.txt | wc -l` # Re-run fails to detect flakes. But use a small threshold, if # something was fundamentally broken, we don't want to re-run @@ -267,7 +267,7 @@ if [ $DEQP_EXITCODE -ne 0 ]; then else grep ",Flake" $RESULTSFILE > $FLAKESFILE - count=`wc -l $FLAKESFILE` + count=`cat $FLAKESFILE | wc -l` if [ $count -gt 0 ]; then echo "Some flakes found (see cts-runner-flakes.txt in artifacts for full results):" head -n 50 $FLAKESFILE -- 2.30.2