[SCM] exiv2 packaging branch, master, updated. debian/0.25-3.1-3734-gdcbc29a
Maximiliano Curia
maxy at moszumanska.debian.org
Thu Jul 13 17:36:45 UTC 2017
Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/exiv2.git;a=commitdiff;h=ab80032
The following commit has been merged in the master branch:
commit ab80032a42d0e8f43578f15c5d1f500140e72ffb
Author: Andreas Huggel <ahuggel at gmx.net>
Date: Sat Nov 20 13:43:35 2004 +0000
Moved test drivers to ../test/
---
src/imagetest.sh | 104 ------------------------------------------
src/iptctest.sh | 133 ------------------------------------------------------
src/write-test.sh | 53 ----------------------
3 files changed, 290 deletions(-)
diff --git a/src/imagetest.sh b/src/imagetest.sh
deleted file mode 100755
index 7507f85..0000000
--- a/src/imagetest.sh
+++ /dev/null
@@ -1,104 +0,0 @@
-#! /bin/bash
-# Test driver for image file i/o
-
-eraseTest()
-{
- src=$1
- test=${src}.etst
- good=${src}.egd
-
- #setup
- cp $src $test
-
- #run tests
- ../src/metacopy $test $test
-
- #check results
- diffCheck $test $good
- echo -n "."
-}
-
-copyTest()
-{
- num=$1
- src=$2
- dst=$3
- test=${dst}.c${num}tst
- good=${dst}.c${num}gd
-
- #setup
- cp $dst $test
-
- #run tests
- ../src/metacopy -a $src $test
-
- #check results
- diffCheck $test $good
- echo -n "."
-}
-
-iptcTest()
-{
- num=$1
- src=$2
- dst=$3
- test=${dst}.i${num}tst
- good=${dst}.i${num}gd
-
- #setup
- cp $dst $test
-
- #run tests
- ../src/metacopy -ip $src $test
-
- #check results
- diffCheck $test $good
- echo -n "."
-}
-
-
-# Make sure to pass the test file first and the known good file second
-diffCheck()
-{
- test=$1
- good=$2
-
- #run diff and check results
- diff -q --binary $test $good
- if [ $? -ne 0 ]; then
- let ++errors
- else
- rm $test
- fi
-}
-
-test_files="table.jpg smiley1.jpg smiley2.jpg"
-
-let errors=0
-cd ../test
-echo
-
-echo -n "Erase all tests"
-for i in $test_files; do eraseTest $i; done
-eraseTest "glider.exv" #extra test
-
-echo -ne "
Copy all tests"
-let c=0
-for src in $test_files; do
- let ++c
- for dst in $test_files; do copyTest $c $src $dst; done
-done
-
-echo -ne "
Copy iptc tests"
-let c=0
-for src in $test_files; do
- let ++c
- for dst in $test_files; do iptcTest $c $src $dst; done
-done
-
-echo -e "
---------------------------------------------------------"
-if [ $errors -eq 0 ]; then
- echo 'All test cases passed'
-else
- echo $errors 'test case(s) failed!'
-fi
diff --git a/src/iptctest.sh b/src/iptctest.sh
deleted file mode 100755
index d472b6a..0000000
--- a/src/iptctest.sh
+++ /dev/null
@@ -1,133 +0,0 @@
-#! /bin/bash
-# Test driver for Iptc metadata
-
-printTest()
-{
- src=$1
- test=${src}.iptst
- good=${src}.ipgd
-
- #run tests
- ../src/iptcprint $src > $test
-
- #check results
- diffCheck $test $good
- echo -n "."
-}
-
-removeTest()
-{
- src=$1
- tmp="temp"
- test=${src}.irtst
- good=${src}.irgd
-
- #setup
- cp $src $tmp
-
- #run tests
- ../src/iptctest $tmp <<-eoc
- r Iptc.Application2.Byline
- r Iptc.Application2.Caption
- r Iptc.Application2.Keywords
- r Iptc.Application2.Keywords
- r Iptc.Application2.Keywords
- r Iptc.Application2.CountryName
-eoc
- ../src/iptcprint $tmp > $test
-
- #check results
- diffCheck $test $good
- echo -n "."
- rm $tmp
-}
-
-addModTest()
-{
- src=$1
- tmp="temp"
- test=${src}.iatst
- good=${src}.iagd
-
- #setup
- cp $src $tmp
-
- #run tests
- ../src/iptctest $tmp <<-eoc
- a Iptc.Application2.Headline The headline I am
- a Iptc.Application2.Keywords Yet another keyword
- m Iptc.Application2.DateCreated 2004-8-3
- a Iptc.Application2.Urgency 3
- m Iptc.Application2.SuppCategory "bla bla ba"
- a Iptc.Envelope.ModelVersion 2
- a Iptc.Envelope.TimeSent 14:41:0-05:00
- a Iptc.Application2.RasterizedCaption 230 42 34 2 90 84 23 146
-eoc
- ../src/iptcprint $tmp > $test
-
- #check results
- diffCheck $test $good
- echo -n "."
- rm $tmp
-}
-
-extendedTest()
-{
- src=$1
- tmp="temp"
- test=${src}.ixtst
- good=${src}.ixgd
-
- #setup
- cp $src $tmp
-
- #run tests
- ../src/iptctest $tmp < ext.dat
- ../src/iptcprint $tmp > $test
-
- #check results
- diffCheck $test $good
- echo -n "."
- rm $tmp
-}
-
-
-# Make sure to pass the test file first and the known good file second
-diffCheck()
-{
- test=$1
- good=$2
-
- #run diff and check results
- diff -q --strip-trailing-cr $test $good
- if [ $? -ne 0 ]; then
- let ++errors
- else
- rm $test
- fi
-}
-
-test_files="smiley1.jpg smiley2.jpg glider.exv table.jpg"
-
-let errors=0
-cd ../test
-echo
-
-echo -n "Read tests"
-for i in $test_files; do printTest $i; done
-
-echo -ne "
Remove tests"
-for i in $test_files; do removeTest $i; done
-
-echo -ne "
Add/Mod tests"
-for i in $test_files; do addModTest $i; done
-
-echo -ne "
Extended tests"
-for i in $test_files; do extendedTest $i; done
-
-echo -e "
---------------------------------------------------------"
-if [ $errors -eq 0 ]; then
- echo 'All test cases passed'
-else
- echo $errors 'test case(s) failed!'
-fi
diff --git a/src/write-test.sh b/src/write-test.sh
deleted file mode 100755
index 5abcd78..0000000
--- a/src/write-test.sh
+++ /dev/null
@@ -1,53 +0,0 @@
-#! /bin/sh
-# Test driver for the write unit tests
-
-# Function:
-# runTestCase number file
-# Params:
-# number: Test case number
-# file : Input file
-# Abstract:
-# Run the requested test case number with the given file
-runTestCase()
-{
- rtc_number=$1
- rtc_infile=$2
-
- rtc_outfile=test${rtc_number}.jpg
- rtc_jpgthumb=thumb${rtc_number}.jpg
- rtc_tifthumb=thumb${rtc_number}.tif
-
- rm -f $rtc_outfile $rtc_jpgthumb $rtc_tifthumb
- rm -f iii ttt;
-
- echo "------------------------------------------------------------"
- ./exifprint $rtc_infile > iii;
- cp $rtc_infile $rtc_outfile;
- ./write-test $rtc_infile $rtc_number > ttt;
- diff iii ttt
-}
-
-# **********************************************************************
-# main
-
-images="img_1771.jpg \
- kodak-dc210.jpg \
- dscf0176.jpg \
- sigma-d10-IMG10086.jpg \
- nikon-coolpix-990-DSCN1180.jpg \
- nikon-d70-dsc_0063.jpg \
- nikon-e950.jpg"
-
-for i in $images; do cp -f ../test/images/$i ./; done
-
-runTestCase 1 ./img_1771.jpg
-runTestCase 2 ./img_1771.jpg
-runTestCase 3 ./kodak-dc210.jpg
-runTestCase 4 ./img_1771.jpg
-runTestCase 5 ./img_1771.jpg
-runTestCase 6 ./kodak-dc210.jpg
-runTestCase 7 ./dscf0176.jpg
-runTestCase 8 ./sigma-d10-IMG10086.jpg
-runTestCase 9 ./nikon-coolpix-990-DSCN1180.jpg
-runTestCase 10 ./nikon-e950.jpg
-runTestCase 11 ./nikon-d70-dsc_0063.jpg
--
exiv2 packaging
More information about the pkg-kde-commits
mailing list