Module: Mesa
Branch: master
Commit: bb0c659980b7a134c9fb88bda4764c2c0a2b6a84
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=bb0c659980b7a134c9fb88bda4764c2c0a2b6a84

Author: Juan A. Suarez Romero <[email protected]>
Date:   Thu Feb 25 12:21:57 2021 +0100

ci/piglit: fix parallel piglit results

Commit bcea453d4a6 removed the summary from the expected piglit
results, but handling of results when using parallel jobs was also doing
the same, which ends up on removing too many lines from results.

Fixes: bcea453d4a6 ("ci/piglit: Stop including the test counts at the
end of expectations.")

Acked-by: Eric Anholt <[email protected]>
Signed-off-by: Juan A. Suarez Romero <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9286>

---

 .gitlab-ci/piglit/run.sh    |  4 +---
 .gitlab-ci/piglit/run_cl.sh | 10 +++++-----
 2 files changed, 6 insertions(+), 8 deletions(-)

diff --git a/.gitlab-ci/piglit/run.sh b/.gitlab-ci/piglit/run.sh
index 51bad88f380..6bc3fc9ed94 100755
--- a/.gitlab-ci/piglit/run.sh
+++ b/.gitlab-ci/piglit/run.sh
@@ -255,9 +255,7 @@ fi
 if [ -n "$USE_CASELIST" ]; then
     # Just filter the expected results based on the tests that were actually
     # executed, and switch to the version with no summary
-    cat $RESULTSFILE | head -n -16 > 
".gitlab-ci/piglit/$PIGLIT_RESULTS.txt.new"
-    RESULTSFILE=".gitlab-ci/piglit/$PIGLIT_RESULTS.txt.new"
-    cat ".gitlab-ci/piglit/$PIGLIT_RESULTS.txt.orig" | head -n -17 | rev \
+    cat ".gitlab-ci/piglit/$PIGLIT_RESULTS.txt.orig" | sed '/^summary:/Q' | 
rev \
         | cut -f2- -d: | rev | sed "s/$/:/g" > /tmp/executed.txt
 
     grep -F -f /tmp/executed.txt "$INSTALL/$PIGLIT_RESULTS.txt" \
diff --git a/.gitlab-ci/piglit/run_cl.sh b/.gitlab-ci/piglit/run_cl.sh
index 74d1ff9a37f..e08b8c29b59 100755
--- a/.gitlab-ci/piglit/run_cl.sh
+++ b/.gitlab-ci/piglit/run_cl.sh
@@ -44,6 +44,7 @@ set -e
 PIGLIT_RESULTS=${PIGLIT_RESULTS:-$PIGLIT_PROFILES}
 mkdir -p .gitlab-ci/piglit
 ./piglit summary console $OLDPWD/results \
+  | tee ".gitlab-ci/piglit/$PIGLIT_RESULTS.txt.orig" \
   | head -n -1 \
   | grep -v ": pass" \
   | sed '/^summary:/Q' \
@@ -52,21 +53,20 @@ mkdir -p .gitlab-ci/piglit
 if [ -n "$USE_CASELIST" ]; then
     # Just filter the expected results based on the tests that were actually
     # executed, and switch to the version with no summary
-    cat .gitlab-ci/piglit/$PIGLIT_RESULTS.txt | head -n -16 | tee 
.gitlab-ci/piglit/$PIGLIT_RESULTS.txt.new \
-         | rev | cut -f2- -d: | rev | sed "s/$/:/g" > /tmp/executed.txt
+    cat .gitlab-ci/piglit/$PIGLIT_RESULTS.txt.orig | sed '/^summary:/Q' | rev \
+         | cut -f2- -d: | rev | sed "s/$/:/g" > /tmp/executed.txt
     grep -F -f /tmp/executed.txt $OLDPWD/install/$PIGLIT_RESULTS.txt \
          > .gitlab-ci/piglit/$PIGLIT_RESULTS.txt.baseline || true
 else
     cp $OLDPWD/install/$PIGLIT_RESULTS.txt 
.gitlab-ci/piglit/$PIGLIT_RESULTS.txt.baseline
-    cp .gitlab-ci/piglit/$PIGLIT_RESULTS.txt 
.gitlab-ci/piglit/$PIGLIT_RESULTS.txt.new
 fi
 
-if diff -q .gitlab-ci/piglit/$PIGLIT_RESULTS.txt.{baseline,new}; then
+if diff -q .gitlab-ci/piglit/$PIGLIT_RESULTS.txt{.baseline,}; then
     exit 0
 fi
 
 ./piglit summary html --exclude-details=pass $OLDPWD/summary $OLDPWD/results
 
 echo Unexpected change in results:
-diff -u .gitlab-ci/piglit/$PIGLIT_RESULTS.txt.{baseline,new}
+diff -u .gitlab-ci/piglit/$PIGLIT_RESULTS.txt{.baseline,}
 exit 1

_______________________________________________
mesa-commit mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to