Skip to content

Commit b9612ff

Browse files
author
giraffedata
committed
Add roundtrip tests for sbig, st4
git-svn-id: https://svn.code.sf.net/p/netpbm/code/trunk@2409 9d0c8265-081b-0410-96cb-a4ca84ce46f8
1 parent f0fa673 commit b9612ff

7 files changed

+41
-0
lines changed

test/Test-Order

+2
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,8 @@ png-roundtrip.test
128128
ps-roundtrip.test
129129
ps-alt-roundtrip.test
130130
sgi-roundtrip.test
131+
sbig-roundtrip.test
132+
st4-roundtrip.test
131133
sunrast-roundtrip.test
132134
targa-roundtrip.test
133135
tiff-roundtrip.test

test/all-in-place.ok

+4
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,8 @@ pgmtolispm: ok
182182
pgmtopbm: ok
183183
pgmtopgm: ok
184184
pgmtoppm: ok
185+
pgmtosbig: ok
186+
pgmtost4: ok
185187
pi1toppm: ok
186188
pi3topbm: ok
187189
picttoppm: ok
@@ -318,6 +320,7 @@ spctoppm: ok
318320
spottopgm: ok
319321
sputoppm: ok
320322
srftopam: ok
323+
st4topgm: ok
321324
sunicontopnm: ok
322325
svgtopam: ok
323326
tgatoppm: ok
@@ -334,6 +337,7 @@ xwdtopnm: ok
334337
ybmtopbm: ok
335338
yuvsplittoppm: ok
336339
yuvtoppm: ok
340+
yuy2topam: ok
337341
zeisstopnm: ok
338342
fiascotopnm: ok
339343
manweb: ok

test/all-in-place.test

+4
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,8 @@ ordinary_testprogs="\
221221
pgmtopbm \
222222
pgmtopgm \
223223
pgmtoppm \
224+
pgmtosbig \
225+
pgmtost4 \
224226
pi1toppm \
225227
pi3topbm \
226228
picttoppm \
@@ -357,6 +359,7 @@ ordinary_testprogs="\
357359
spottopgm \
358360
sputoppm \
359361
srftopam \
362+
st4topgm \
360363
sunicontopnm \
361364
svgtopam \
362365
tgatoppm \
@@ -373,6 +376,7 @@ ordinary_testprogs="\
373376
ybmtopbm \
374377
yuvsplittoppm \
375378
yuvtoppm \
379+
yuy2topam \
376380
zeisstopnm \
377381
"
378382

test/sbig-roundtrip.ok

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
1571496937 33838

test/sbig-roundtrip.test

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#! /bin/bash
2+
# This script tests: pgmtosbig sbigtopgm
3+
# Also requires: pamchannel
4+
5+
alias sbigtopgm="${PBM_TESTPREFIX}sbigtopgm"
6+
alias pgmtosbig="${PBM_TESTPREFIX}pgmtosbig"
7+
shopt -s expand_aliases
8+
9+
# Should produce 1571496937 33838, cksum of testimg.red
10+
11+
pamchannel -infile=testimg.ppm -tupletype="GRAYSCALE" 0 | pamtopnm | \
12+
pgmtosbig | sbigtopgm | cksum

test/st4-roundtrip.ok

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
185194654 31695

test/st4-roundtrip.test

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#! /bin/bash
2+
# This script tests: pgmtost4 st4topgm
3+
# Also requires: pamchannel pamtopnm pamcut
4+
5+
alias st4topgm="${PBM_TESTPREFIX}st4topgm"
6+
alias pgmtost4="${PBM_TESTPREFIX}pgmtost4"
7+
shopt -s expand_aliases
8+
9+
# Input image of pgmtost4 must by 192x165
10+
11+
# Should produce 185194654 31695 which is the output of:
12+
# pamchannel -infile=testimg.ppm -tupletype="GRAYSCALE" 0 | \
13+
# pamtopnm | pamcut -pad 0 0 192 165 | cksum
14+
15+
pamchannel -infile=testimg.ppm -tupletype="GRAYSCALE" 0 | \
16+
pamtopnm | pamcut -pad 0 0 192 165 | \
17+
pgmtost4 | st4topgm - | cksum

0 commit comments

Comments
 (0)