kopia lustrzana https://gitlab.com/sane-project/backends
Changed testsuite to use the test backend instead of the pnm backend. This
actually works with current sane-backends.merge-requests/1/head
rodzic
6f039aa829
commit
122295e297
|
@ -61,6 +61,9 @@
|
|||
the files and directories of sane-backends. Fixed building
|
||||
instructions for tstbackend. Mentioned that sane_* symbols
|
||||
should be only used for API symbols.
|
||||
* testsuite/Makefile.in testsuite/README testsuite/testfile.pnm:
|
||||
Changed testsuite to use the test backend instead of the pnm
|
||||
backend. This actually works with current sane-backends.
|
||||
|
||||
2006-01-03 Henning Meier-Geinitz <henning@meier-geinitz.de>
|
||||
|
||||
|
|
|
@ -35,8 +35,9 @@ RANLIB = @RANLIB@
|
|||
|
||||
SCANIMAGE = ../frontend/scanimage
|
||||
TESTFILE = testfile.pnm
|
||||
DEVICE = pnm:0
|
||||
OPTIONS = --filename=$(TESTFILE)
|
||||
OUTFILE = outfile.pnm
|
||||
DEVICE = test
|
||||
OPTIONS = --mode Color --depth 16 --test-picture "Color pattern" --resolution 50 -y 20 -x 20 > $(OUTFILE)
|
||||
|
||||
DISTCLEAN_FILES = @DISTCLEAN_FILES@
|
||||
|
||||
|
@ -50,16 +51,24 @@ all: Makefile
|
|||
test: Makefile test.local
|
||||
|
||||
test.local:
|
||||
@echo "Testing $(SCANIMAGE) with device $(DEVICE)"
|
||||
@if echo "Trying flatbed scanner" && \
|
||||
$(SCANIMAGE) -d $(DEVICE) $(OPTIONS) -T && \
|
||||
echo "Trying three pass flatbed scanner" && \
|
||||
$(SCANIMAGE) -d $(DEVICE) $(OPTIONS) --three-pass=yes -T && \
|
||||
echo "Trying hand scanner" && \
|
||||
$(SCANIMAGE) -d $(DEVICE) $(OPTIONS) --hand-scanner=yes -T ; \
|
||||
then echo ; echo ; echo "All tests passed" ; \
|
||||
@echo "**** Testing $(SCANIMAGE) with device $(DEVICE)"
|
||||
@if echo "---> Trying flatbed scanner" && \
|
||||
$(SCANIMAGE) -d $(DEVICE) -T && \
|
||||
echo "<--- Flatbed scanner succeded" && \
|
||||
echo "---> Trying three pass flatbed scanner" && \
|
||||
$(SCANIMAGE) -d $(DEVICE) --mode Color --three-pass=yes -T && \
|
||||
echo "<--- Three pass scanner succeded" && \
|
||||
echo "---> Trying hand scanner" && \
|
||||
$(SCANIMAGE) -d $(DEVICE) --hand-scanner=yes -T && \
|
||||
echo "<--- Hand scanner succeded" && \
|
||||
echo "---> Checking 16 bit color mode" && \
|
||||
$(SCANIMAGE) -d $(DEVICE) $(OPTIONS) && \
|
||||
cmp -s $(TESTFILE) $(OUTFILE) && \
|
||||
echo "<--- 16 bit color mode succeded" && \
|
||||
rm $(OUTFILE) ; \
|
||||
then echo ; echo ; echo "**** All tests passed" ; \
|
||||
else echo ; echo; \
|
||||
echo "Something failed (maybe pnm backend not enabled by configure?)";\
|
||||
echo "**** Something failed (maybe test backend not enabled by configure?)";\
|
||||
fi
|
||||
|
||||
# Generate new Makefile when something changes
|
||||
|
@ -68,6 +77,7 @@ Makefile: Makefile.in ../config.status
|
|||
&& CONFIG_FILES=testsuite/Makefile CONFIG_HEADERS= /bin/sh ./config.status
|
||||
|
||||
clean:
|
||||
rm -f $(OUTFILE)
|
||||
|
||||
distclean: clean
|
||||
rm -f $(DISTCLEAN_FILES)
|
||||
|
|
|
@ -8,5 +8,8 @@ everything without installing, to make sure a new distribution is
|
|||
function properly before the old one is replaced. If it isn't, please
|
||||
fix the bug. :-)
|
||||
|
||||
The current test needs the pnm backend. Hint:
|
||||
"configure --enable-pnm-backend".
|
||||
The current tests use the test backend to scan in flatbed, hand scanner and
|
||||
three pass mode. Also a 16 bit color image is created and compared to the
|
||||
"right" one. This test should detect any little/big endian issues in scanimage.
|
||||
|
||||
|
||||
|
|
Plik binarny nie jest wyświetlany.
Ładowanie…
Reference in New Issue