annotate tests/0025/run-test.sh @ 277:abfb26e08d9c audiodb-debian

Merge trunk changes -r326:386 into audiodb-debian branch. Plus new debian/changelog version. (Should have used an epoch really, but couldn't be bothered; TODO: work out a sane version numbering policy).
author mas01cr
date Tue, 01 Jul 2008 09:12:40 +0000
parents 100b7ba08df3
children
rev   line source
mas01cr@277 1 #! /bin/bash
mas01cr@167 2
mas01cr@167 3 . ../test-utils.sh
mas01cr@167 4
mas01cr@167 5 if [ -f testdb ]; then rm -f testdb; fi
mas01cr@167 6
mas01cr@167 7 ${AUDIODB} -d testdb -N
mas01cr@167 8
mas01cr@167 9 intstring 2 > testfeature
mas01cr@167 10 floatstring 0 0.5 >> testfeature
mas01cr@167 11 floatstring 0.5 0 >> testfeature
mas01cr@167 12
mas01cr@167 13 cat > testtimes <<EOF
mas01cr@167 14 0
mas01cr@167 15 1
mas01cr@167 16 2
mas01cr@167 17 EOF
mas01cr@167 18
mas01cr@167 19 ${AUDIODB} -d testdb -I -f testfeature -t testtimes
mas01cr@167 20
mas01cr@167 21 # sequence queries require L2NORM
mas01cr@167 22 ${AUDIODB} -d testdb -L
mas01cr@167 23
mas01cr@167 24 echo "query point (0.0,0.5)"
mas01cr@167 25 intstring 2 > testquery
mas01cr@167 26 floatstring 0 0.5 >> testquery
mas01cr@167 27
mas01cr@167 28 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery > testoutput
mas01cr@167 29 echo testfeature 1 0 0 > test-expected-output
mas01cr@167 30 cmp testoutput test-expected-output
mas01cr@167 31 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -n 1 > testoutput
mas01cr@167 32 echo testfeature 0 0 0 > test-expected-output
mas01cr@167 33 cmp testoutput test-expected-output
mas01cr@167 34
mas01cr@167 35 echo "query point (0.5,0.0)"
mas01cr@167 36 intstring 2 > testquery
mas01cr@167 37 floatstring 0.5 0 >> testquery
mas01cr@167 38
mas01cr@167 39 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery > testoutput
mas01cr@167 40 echo testfeature 1 0 1 > test-expected-output
mas01cr@167 41 cmp testoutput test-expected-output
mas01cr@167 42 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -n 1 > testoutput
mas01cr@167 43 echo testfeature 0 0 1 > test-expected-output
mas01cr@167 44 cmp testoutput test-expected-output
mas01cr@167 45
mas01cr@167 46 exit 104