diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2023-06-28 17:29:32 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2023-06-28 17:29:32 +0000 |
commit | 23ce26f64c34e30951ad9ade2151552ed77e7357 (patch) | |
tree | d73b31a0c2f7c7be4a69f8a8e84e00dd39c432b5 /test/pi3-roundtrip.test | |
parent | 1b6e51a266008348ad93ed8b6ac9ec91b5024fea (diff) | |
download | netpbm-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/pi3-roundtrip.test')
-rwxr-xr-x | test/pi3-roundtrip.test | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/test/pi3-roundtrip.test b/test/pi3-roundtrip.test index 5700337d..d795157d 100755 --- a/test/pi3-roundtrip.test +++ b/test/pi3-roundtrip.test @@ -1,16 +1,15 @@ -#! /bin/bash +#! /bin/sh # This script tests: pbmtopi3 pi3topbm -# Also requires: pbmmake pamcut - +# Also requires: pbmmake pamcut pamfile # The pi3 image format specifies a fixed image size of 640x400. # Pbmtopi3 rejects images that do not conform. -# Test -# Should print: 3139449799 32011 +echo "Test 1. Should print: 3139449799 32011 twice" +pbmmake -g 640 400 | cksum pbmmake -g 640 400 | pbmtopi3 | pi3topbm | cksum -# Test 2. -# Should print: 2425386270 41 -pamcut -pad 0 0 640 400 testgrid.pbm | \ - pbmtopi3 | pi3topbm | pamcut 0 0 14 16 | cksum +echo "Test 2. Should print: 281226646 481, cksum of maze.pbm" +size=$(pamfile -size maze.pbm | awk '{print "-width="$1,"-height="$2}') +pamcut -pad -left=0 -top=0 -width=640 -height=400 maze.pbm | \ + pbmtopi3 | pi3topbm | pamcut -left=0 -top=0 ${size} | cksum |