annotate tests/0031/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 a7df1dc971ef
children
rev   line source
mas01cr@277 1 #! /bin/bash
mas01cr@197 2
mas01cr@197 3 . ../test-utils.sh
mas01cr@197 4
mas01cr@197 5 if [ -f testdb ]; then rm -f testdb; fi
mas01cr@197 6
mas01cr@197 7 ${AUDIODB} -d testdb -N
mas01cr@197 8
mas01cr@197 9 intstring 2 > testfeature01
mas01cr@197 10 floatstring 0 1 >> testfeature01
mas01cr@197 11 intstring 2 > testfeature10
mas01cr@197 12 floatstring 1 0 >> testfeature10
mas01cr@197 13
mas01cr@197 14 ${AUDIODB} -d testdb -I -f testfeature01
mas01cr@197 15 ${AUDIODB} -d testdb -I -f testfeature10
mas01cr@197 16
mas01cr@197 17 # sequence queries require L2NORM
mas01cr@197 18 ${AUDIODB} -d testdb -L
mas01cr@197 19
mas01cr@197 20 echo "query point (0.0,0.5)"
mas01cr@197 21 intstring 2 > testquery
mas01cr@197 22 floatstring 0 0.5 >> testquery
mas01cr@197 23
mas01cr@197 24 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery > testoutput
mas01cr@197 25 echo testfeature01 0 0 0 > test-expected-output
mas01cr@197 26 echo testfeature10 2 0 0 >> test-expected-output
mas01cr@197 27 cmp testoutput test-expected-output
mas01cr@197 28 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K /dev/null > testoutput
mas01cr@197 29 cat /dev/null > test-expected-output
mas01cr@197 30 cmp testoutput test-expected-output
mas01cr@197 31
mas01cr@197 32 echo testfeature01 > testkl.txt
mas01cr@197 33 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K testkl.txt > testoutput
mas01cr@197 34 echo testfeature01 0 0 0 > test-expected-output
mas01cr@197 35 cmp testoutput test-expected-output
mas01cr@197 36
mas01cr@197 37 echo testfeature10 > testkl.txt
mas01cr@197 38 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K testkl.txt > testoutput
mas01cr@197 39 echo testfeature10 2 0 0 > test-expected-output
mas01cr@197 40 cmp testoutput test-expected-output
mas01cr@197 41
mas01cr@197 42 echo testfeature10 > testkl.txt
mas01cr@197 43 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K testkl.txt -r 1 > testoutput
mas01cr@197 44 echo testfeature10 2 0 0 > test-expected-output
mas01cr@197 45 cmp testoutput test-expected-output
mas01cr@197 46
mas01cr@197 47 echo "query point (0.5,0.0)"
mas01cr@197 48 intstring 2 > testquery
mas01cr@197 49 floatstring 0.5 0 >> testquery
mas01cr@197 50
mas01cr@197 51 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery > testoutput
mas01cr@197 52 echo testfeature10 0 0 0 > test-expected-output
mas01cr@197 53 echo testfeature01 2 0 0 >> test-expected-output
mas01cr@197 54 cmp testoutput test-expected-output
mas01cr@197 55 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K /dev/null > testoutput
mas01cr@197 56 cat /dev/null > test-expected-output
mas01cr@197 57 cmp testoutput test-expected-output
mas01cr@197 58
mas01cr@197 59 echo testfeature10 > testkl.txt
mas01cr@197 60 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K testkl.txt > testoutput
mas01cr@197 61 echo testfeature10 0 0 0 > test-expected-output
mas01cr@197 62 cmp testoutput test-expected-output
mas01cr@197 63
mas01cr@197 64 echo testfeature01 > testkl.txt
mas01cr@197 65 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K testkl.txt > testoutput
mas01cr@197 66 echo testfeature01 2 0 0 > test-expected-output
mas01cr@197 67 cmp testoutput test-expected-output
mas01cr@197 68
mas01cr@197 69 echo testfeature01 > testkl.txt
mas01cr@197 70 ${AUDIODB} -d testdb -Q sequence -l 1 -f testquery -K testkl.txt -r 1 > testoutput
mas01cr@197 71 echo testfeature01 2 0 0 > test-expected-output
mas01cr@197 72 cmp testoutput test-expected-output
mas01cr@197 73
mas01cr@197 74 exit 104