696cfa1bdd62d201e78cc417142e18e5831951d9
[idzebra-moved-to-github.git] / test / charmap / test1.sh
1 #!/bin/sh
2 # $Id: test1.sh,v 1.4 2004-09-27 10:44:50 adam Exp $
3
4 pp=${srcdir:-"."}
5
6 LOG=test1.log
7 rm -f $LOG
8 if ../../index/zebraidx -c $pp/zebra.cfg -l $LOG filters|grep grs.xml >/dev/null; then
9         ../../index/zebraidx -c $pp/zebra.cfg -l$LOG init
10 else
11         exit 0
12 fi
13 ../../index/zebraidx -c $pp/zebra.cfg -l$LOG update $pp/*.xml
14 ../../index/zebrasrv -c $pp/zebra.cfg -l$LOG unix:socket &
15 sleep 1
16 ../api/testclient unix:socket '@term string æ' >tmp1
17 echo 'Result count: 1' >tmp2
18 kill `cat zebrasrv.pid` || exit 1
19 diff tmp1 tmp2 || exit 2
20 rm -f tmp1 tmp2