gbranden pushed a commit to branch master
in repository groff.
commit b5ab790488aa25cee5cc41c85875f46268d08a67
Author: G. Branden Robinson <[email protected]>
AuthorDate: Fri Sep 11 01:04:08 2026 -0500
[refer]: Prepare test script for multiple checks.
* src/preproc/refer/tests/check-index-file-validity.sh: Do it.
---
src/preproc/refer/tests/check-index-file-validity.sh | 15 +++++++++++----
1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/src/preproc/refer/tests/check-index-file-validity.sh
b/src/preproc/refer/tests/check-index-file-validity.sh
index 449dcb41f..fb20058df 100755
--- a/src/preproc/refer/tests/check-index-file-validity.sh
+++ b/src/preproc/refer/tests/check-index-file-validity.sh
@@ -20,7 +20,12 @@
indxbib="${abs_top_builddir:-.}/indxbib"
lkbib="${abs_top_builddir:-.}/lkbib"
-# Regression-test Savannah #68679.
+fail=
+
+wail () {
+ echo ...FAILED >&2
+ fail=YES
+}
# Index files are in host-dependent data format. Skip this test if
# we're not on the most common (and worst) host environment.
@@ -65,6 +70,8 @@ then
exit 77 # skip
fi
+# Regression-test Savannah #68679.
+
REFER="$sandbox_dir"/little-schemer.bib
export REFER
@@ -80,12 +87,12 @@ fi
# other shells don't either, and expecting one that does to be in the
# $PATH seems optimistic.
printf '\377\377\377\377' | dd of="$REFER".i bs=1 seek=24 conv=notrunc
-status=1
-"$lkbib" Schemer 2>&1 > /dev/null | grep -q 'error.*corrupt' && status=0
+echo "checking behavior when index file parameters corrupt" >&2
+"$lkbib" Schemer 2>&1 > /dev/null | grep -q 'error.*corrupt' || wail
# We need `-f` because "little-schemer.bib" gets mode 444 in a "make
# distcheck" build.
rm -rf "$sandbox_dir"
-exit $status
+test -z "$fail" || exit 1
# vim:set autoindent expandtab shiftwidth=4 tabstop=4 textwidth=72:
_______________________________________________
groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit