gbranden pushed a commit to branch master
in repository groff.

commit 350e6abe8fd9170a10da13937c015045a2df1143
Author: G. Branden Robinson <[email protected]>
AuthorDate: Sun Feb 11 02:21:07 2024 -0600

    [tbl,tests]: Apply recent idiom consistently.
    
    We weren't testing the shell variable `fail` for emptiness at the end of
    the script.  This didn't matter becuse there's only one check in this
    script anyway, and it was exiting with the status of the relevant
    command, but if we add more checks it could cause misleading results.
    (For example, if check 1 failed but check 2 succeeded, the script would
    have falsely reported a pass.)
---
 src/preproc/tbl/tests/align-staggered-text-blocks-correctly.sh | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/preproc/tbl/tests/align-staggered-text-blocks-correctly.sh 
b/src/preproc/tbl/tests/align-staggered-text-blocks-correctly.sh
index 167884481..b3c2caf35 100755
--- a/src/preproc/tbl/tests/align-staggered-text-blocks-correctly.sh
+++ b/src/preproc/tbl/tests/align-staggered-text-blocks-correctly.sh
@@ -59,4 +59,6 @@ output=$(printf "%s\n" "$input" | "$groff" -tZ -T ps)
 echo "$output"
 test $(echo "$output" | grep -c 'V *44000') -eq 5
 
+test -z "$fail"
+
 # vim:set ai et sw=4 ts=4 tw=72:

_______________________________________________
Groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit

Reply via email to