From ca0573f4c347ea162a882092e87345e61d708f67 Mon Sep 17 00:00:00 2001 From: Jean Privat Date: Wed, 27 Aug 2014 22:37:34 -0400 Subject: [PATCH] tests: fix errlist Signed-off-by: Jean Privat --- .gitignore | 1 + tests/tests.sh | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 30cf0fc..8ed1a4e 100644 --- a/.gitignore +++ b/.gitignore @@ -44,6 +44,7 @@ contrib/*/bin tests/alt tests/errlist +tests/errlist.bak tests/out tests/*.xml tests/nitunit diff --git a/tests/tests.sh b/tests/tests.sh index 5bdefd2..f1daadd 100755 --- a/tests/tests.sh +++ b/tests/tests.sh @@ -216,6 +216,7 @@ function process_result() cat -v >>$xml out/$pattern.res echo >>$xml "]]>" nos="$nos $pattern" + echo "$ii" >> "$ERRLIST" else # no sav but empty res echo "[0k] out/$pattern.res is empty" @@ -580,10 +581,11 @@ fi # write $ERRLIST if [ "x$ERRLIST" != "x" ]; then - if [ -x "$ERRLIST_TARGET" ]; then + if [ -f "$ERRLIST_TARGET" ]; then mv "$ERRLIST_TARGET" "${ERRLIST_TARGET}.bak" fi - mv $ERRLIST $ERRLIST_TARGET + uniq $ERRLIST > $ERRLIST_TARGET + rm $ERRLIST fi echo >>$xml "" -- 1.7.9.5