gbranden pushed a commit to branch master
in repository groff.
commit a58e6b215a50b155255717b27da30543b0b799d8
Author: G. Branden Robinson <[email protected]>
AuthorDate: Thu May 14 10:12:56 2026 -0500
tmac/tests/doc_Xr-works.sh: Fix code style nits.
* Employ empty requests in test input for better readability.
* Update line number expectations of error-path checks accordingly.
* Fix typo.
* Revise Vim modeline to communicate less esoterically.
---
tmac/tests/doc_Xr-works.sh | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/tmac/tests/doc_Xr-works.sh b/tmac/tests/doc_Xr-works.sh
index 2c5987c85..6b5d02286 100755
--- a/tmac/tests/doc_Xr-works.sh
+++ b/tmac/tests/doc_Xr-works.sh
@@ -26,9 +26,10 @@ wail() {
fail=yes
}
-# Unit test the Xr maco.
+# Unit-test the Xr macro.
-input='.Dd 2024-02-22
+input='.
+.Dd 2024-02-22
.Dt foo 1
.Os "groff test suite"
.Sh Name
@@ -63,7 +64,8 @@ Or
about
.Xr groff Pf - Xr man
and
-.Xr groff Ns - Ns Xr ms .'
+.Xr groff Ns - Ns Xr ms .
+.'
output=$(echo "$input" | "$groff" -rU0 -mdoc -Tascii -P-cbou \
2>/dev/null)
@@ -73,7 +75,7 @@ echo "$output"
echo "$error"
echo "checking for error diagnostic on argumentless Xr call (-rU0)" >&2
-echo "$error" | grep -q '9' || wail
+echo "$error" | grep -q ':10:' || wail
echo "checking two-argument Xr call with full cross reference (-rU0)" \
>&2
@@ -110,7 +112,7 @@ echo "$output"
echo "$error"
echo "checking for error diagnostic on argumentless Xr call (-rU1)" >&2
-echo "$error" | grep -q '9' || wail
+echo "$error" | grep -q ':10:' || wail
echo "checking two-argument Xr call with full cross reference (-rU1)" \
>&2
@@ -141,4 +143,4 @@ echo "$output" | grep -Fq 'Or about groff -man and
groff-ms.' || wail
test -z "$fail"
-# vim:set ai et sw=4 ts=4 tw=72:
+# vim:set autoindent expandtab shiftwidth=4 tabstop=4 textwidth=72:
_______________________________________________
groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit