about summary refs log tree commit diff
path: root/test/ps-roundtrip.test
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-06-28 17:29:32 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-06-28 17:29:32 +0000
commit23ce26f64c34e30951ad9ade2151552ed77e7357 (patch)
treed73b31a0c2f7c7be4a69f8a8e84e00dd39c432b5 /test/ps-roundtrip.test
parent1b6e51a266008348ad93ed8b6ac9ec91b5024fea (diff)
downloadnetpbm-mirror-23ce26f64c34e30951ad9ade2151552ed77e7357.tar.gz
netpbm-mirror-23ce26f64c34e30951ad9ade2151552ed77e7357.tar.xz
netpbm-mirror-23ce26f64c34e30951ad9ade2151552ed77e7357.zip
promote Advanced to Stable
git-svn-id: http://svn.code.sf.net/p/netpbm/code/stable@4558 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'test/ps-roundtrip.test')
-rwxr-xr-xtest/ps-roundtrip.test24
1 files changed, 12 insertions, 12 deletions
diff --git a/test/ps-roundtrip.test b/test/ps-roundtrip.test
index 207646cc..5d7b7d65 100755
--- a/test/ps-roundtrip.test
+++ b/test/ps-roundtrip.test
@@ -1,6 +1,6 @@
-#! /bin/bash
+#! /bin/sh
 # This script tests: pnmtops pstopnm
-# Also requires: pamtopnm gs pbmmake pnmshear pnmpad pnmcat
+# Also requires: pamtopnm gs pbmmake pnmshear pnmpad pamcat
 
 
 # Failure message
@@ -11,7 +11,7 @@ tmpdir=${tmpdir:-/tmp}
 # pstopnm does not use libnetpbm functions for output.
 # Output is filtered through pamtopnm.
 
-# Test 1.  Should print: 1926073387 101484 four times
+echo "Test 1.  Should print 1926073387 101484 four times"
 test1_ps=${tmpdir}/testimg1.ps
 
 for flag in "" "-ps" "-rle" "-ps -ascii"
@@ -25,9 +25,9 @@ for flag in "" "-ps" "-rle" "-ps -ascii"
   done
 
 rm ${test1_ps}
-# Test 2.  Should print: 2918318199 62 seven times
+
+echo "Test 2.  Should print 2918318199 62 seven times"
 # Test image designed to detect problems with run-length compression
-#
 
 g_pbm=${tmpdir}/g.pbm
 t_pbm=${tmpdir}/t.pbm
@@ -37,7 +37,7 @@ pbmmake -g 2 2 > ${g_pbm}
 pbmmake -g 8 4 | \
   pnmshear 45 -noantialias -background=black | \
   pnmpad -right 60 | \
-  pnmcat -tb -jright - ${g_pbm} > ${t_pbm} &&
+  pamcat -tb -jright - ${g_pbm} > ${t_pbm} &&
 for flag in "" "-rle" "-ps -rle -ascii" \
             "-bitspersample=2 -rle" "-ps -bitspersample=4 -rle" \
             "-bitspersample=8 -rle" "-ps -bitspersample=12 -rle -dict"
@@ -52,8 +52,8 @@ for flag in "" "-rle" "-ps -rle -ascii" \
 
 rm ${grid_ps} ${g_pbm} ${t_pbm}
 
-#Test 3. Should print: 1386192571 507420 three times
-#
+echo "Test 3. Should print 1831481505 608904 three times"
+
 # Special care is needed when conducting round-trips with multiple-image
 # files as input.
 # (1) pnmtops: -setpage is mandatory
@@ -61,16 +61,16 @@ rm ${grid_ps} ${g_pbm} ${t_pbm}
 #          Subsequent BoundingBox values are ignored.
 # (3) pstopnm: input must be an ordinary file.  Input from stdin
 #     (by pipe or input redirection: "< file" ) does not work.
-#
 
 test3_ps=${tmpdir}/testimg3.ps
 
 for flag in "" "-ps" \
             "-ps -bitspersample=12 -rle -vmreclaim"
   do
-cat testimg.ppm testimg.ppm testimg.ppm testgrid.pbm testgrid.pbm | \
-pnmtops -nocenter -equalpixels -dpi 72 -noturn -setpage ${flag} \
-  > ${test3_ps} &&
+cat testimg.ppm testimg.ppm testimg.ppm maze.pbm \
+  testgrid.pbm testgrid.pbm | \
+  pnmtops -nocenter -equalpixels -dpi 72 -noturn -setpage ${flag} \
+    > ${test3_ps} &&
 xysize3=`awk  '/BoundingBox/ {print "-xsize="$4,"-ysize="$5 ; exit}' \
   ${test3_ps}` &&
 pstopnm -portrait -xborder=0 -yborder=0 $xysize3 -stdout  ${test3_ps} | \