add a test for fax2tiff tool

This commit is contained in:
Thomas Bernard 2019-03-22 10:00:52 +01:00
parent 88b410f800
commit 933575f505
No known key found for this signature in database
GPG Key ID: 0FF11B67A5C0863C
5 changed files with 23 additions and 0 deletions

View File

@ -35,6 +35,7 @@ set(TESTSCRIPTS
ppm2tiff_pbm.sh ppm2tiff_pbm.sh
ppm2tiff_pgm.sh ppm2tiff_pgm.sh
ppm2tiff_ppm.sh ppm2tiff_ppm.sh
fax2tiff.sh
tiffcp-g3.sh tiffcp-g3.sh
tiffcp-g3-1d.sh tiffcp-g3-1d.sh
tiffcp-g3-1d-fill.sh tiffcp-g3-1d-fill.sh
@ -151,6 +152,7 @@ set(UNCOMPRESSEDIMAGES
# files which are not currently used by the tests. # files which are not currently used by the tests.
set(IMAGES_EXTRA_DIST set(IMAGES_EXTRA_DIST
images/README.txt images/README.txt
images/miniswhite-1c-1b.g3
${BMPIMAGES} ${BMPIMAGES}
${GIFIMAGES} ${GIFIMAGES}
${PNMIMAGES} ${PNMIMAGES}

View File

@ -70,6 +70,7 @@ TESTSCRIPTS = \
ppm2tiff_pbm.sh \ ppm2tiff_pbm.sh \
ppm2tiff_pgm.sh \ ppm2tiff_pgm.sh \
ppm2tiff_ppm.sh \ ppm2tiff_ppm.sh \
fax2tiff.sh \
tiffcp-g3.sh \ tiffcp-g3.sh \
tiffcp-g3-1d.sh \ tiffcp-g3-1d.sh \
tiffcp-g3-1d-fill.sh \ tiffcp-g3-1d-fill.sh \
@ -172,6 +173,7 @@ PNMIMAGES = \
# files which are not currently used by the tests. # files which are not currently used by the tests.
IMAGES_EXTRA_DIST = \ IMAGES_EXTRA_DIST = \
images/README.txt \ images/README.txt \
images/miniswhite-1c-1b.g3 \
$(PNMIMAGES) \ $(PNMIMAGES) \
$(TIFFIMAGES) $(TIFFIMAGES)

16
test/fax2tiff.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/sh
#
# Basic sanity check for fax2tiff
#
. ${srcdir:-.}/common.sh
infile="${IMAGES}/miniswhite-1c-1b.g3"
outfile="o-fax2tiff.tiff"
echo "$MEMCHECK ${FAX2TIFF} -M -o $outfile $infile"
eval "$MEMCHECK" "${FAX2TIFF}" "-M" "-o" "$outfile" "$infile"
status=$?
if [ $status != 0 ] ; then
echo "Returned failed status $status!"
echo "Output (if any) is in \"${outfile}\"."
exit $status
fi
f_tiffinfo_validate $outfile

View File

@ -27,3 +27,6 @@ PNM files:
minisblack-1c-8b.pgm minisblack-1c-8b.pgm
miniswhite-1c-1b.pbm miniswhite-1c-1b.pbm
rgb-3c-8b.ppm rgb-3c-8b.ppm
G3 Fax files :
miniswhite-1c-1b.g3

Binary file not shown.