Makefile updates for Automake 1.5+. Test script updates
[idzebra-moved-to-github.git] / test / sort / test1.sh
1 #!/bin/sh
2 # $Id: test1.sh,v 1.3 2003-05-21 14:39:22 adam Exp $
3 LOG=test1.log
4 rm -fr lock
5 mkdir lock
6 rm -fr reg
7 mkdir reg
8 rm -fr recs
9 mkdir recs
10 cp rec*.xml recs
11 ../../index/zebraidx -l $LOG update recs || exit 1
12 ../../index/zebrasrv -l $LOG unix:socket &
13 sleep 1
14 test -f zebrasrv.pid || exit 2
15 ../api/testclient -n3 unix:socket '@or computer @attr 7=1 @attr 1=30 0' >tmp1
16 echo 'Result count: 3
17 my:
18   title: third computer
19 my:
20   title: second computer
21   dateTime: 1
22 my:
23   title: first computer
24   dateTime: 2' >tmp2
25
26 kill `cat zebrasrv.pid`
27 diff tmp1 tmp2