gbranden pushed a commit to branch master
in repository groff.

commit bed13e17e50e80a20e42bd396857cb55cb1d0418
Author: G. Branden Robinson <[email protected]>
AuthorDate: Fri Oct 18 14:53:07 2024 -0500

    [groff]: Tweak test script.
    
    * Drop unnecessary logic (can't store stderr output when stderr is
      thrown away).
    * Drop unnecessary `fl` requests from test input.
    * Mark output more explicitly since this test is tougher to read than
      most.
---
 .../device-control-special-character-handling.sh   | 22 ++++++++--------------
 1 file changed, 8 insertions(+), 14 deletions(-)

diff --git a/src/roff/groff/tests/device-control-special-character-handling.sh 
b/src/roff/groff/tests/device-control-special-character-handling.sh
index 320fb71ef..0321eda91 100755
--- a/src/roff/groff/tests/device-control-special-character-handling.sh
+++ b/src/roff/groff/tests/device-control-special-character-handling.sh
@@ -38,10 +38,7 @@ input='.
 
 output=$(printf '%s\n' "$input" | "$groff" -T ps -Z 2> /dev/null \
   | grep '^x X')
-error=$(printf '%s\n' "$input" | "$groff" -T ps -Z 2>&1 > /dev/null)
-
 echo "$output"
-echo "$error"
 
 # Expected:
 #
@@ -102,17 +99,17 @@ echo "$output" | grep -Fqx 'x X bogus5: {||}~' || wail
 input='.
 .ds h Caf\['"'"'e] Hyphen-Minus and \[rs]\[u2010]
 \X"ps:exec 1:\\X     [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT pdfmark"
-.fl
 \!x X ps:exec 2:\!     [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT pdfmark
 .device ps:exec 3:device [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT pdfmark
-.fl
 .output x X ps:exec 4:output [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT 
pdfmark
 .'
 
+echo INPUT:
+printf '%s\n' "$input" | nl
+
 output=$(printf '%s\n' "$input" | "$groff" -T pdf -Z 2> /dev/null \
   | grep '^x X')
-error=$(printf '%s\n' "$input" | "$groff" -ww -T pdf -z)
-echo "$error"
+echo OUTPUT:
 printf "%s\n" "$output"
 
 # Expected:
@@ -144,26 +141,23 @@ printf "%s\n" "$output" \
   | grep -Fqx 'x X ps:exec 4:output [/Dest /pdf:bm1 /Title (Caf\['"'"'e] 
Hyphen-Minus and \[rs]\[u2010]) /Level 1 /OUT pdfmark' \
   || wail
 
-#test -z "$fail"
-#exit
-
 # Test the same thing, but with a composite special character escape
 # sequence.
 
 input='.
 .ds h Caf\[e aa] Hyphen-Minus and \[rs]\[u2010]
 \X"ps:exec 5:\\X     [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT pdfmark"
-.fl
 \!x X ps:exec 6:\!     [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT pdfmark
 .device ps:exec 7:device [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT pdfmark
-.fl
 .output x X ps:exec 8:output [/Dest /pdf:bm1 /Title (\*[h]) /Level 1 /OUT 
pdfmark
 .'
 
+echo INPUT:
+printf '%s\n' "$input" | nl
+
 output=$(printf '%s\n' "$input" | "$groff" -T pdf -Z 2> /dev/null \
   | grep '^x X')
-error=$(printf '%s\n' "$input" | "$groff" -ww -T pdf -z)
-echo "$error"
+echo OUTPUT:
 printf "%s\n" "$output"
 
 # Expected:

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

Reply via email to