More test updates
[idzebra-moved-to-github.git] / test / gils / stop04.sh
index 2b06077..bce26c3 100755 (executable)
@@ -1,5 +1,5 @@
 #!/bin/sh
-# $Id: stop04.sh,v 1.2 2003-05-06 17:39:01 adam Exp $
+# $Id: stop04.sh,v 1.3 2003-05-06 20:09:28 adam Exp $
 # test start and stop of the forked server 
 #
 
@@ -23,14 +23,14 @@ sleep 1
 echo "  checking that it runs... "
 test -f zebrasrv.pid || exit 1
 PID=`cat zebrasrv.pid`
-ps -p $PID >/dev/null || exit 1
+ps -p $PID | grep $PID >/dev/null || exit 1
 
 echo "  connecting to it..."
 ../testclient localhost:9901 utah > log || exit 1
 sleep 1
 
 echo "  checking that it still runs..."
-ps -p $PID >/dev/null || exit 1
+ps -p $PID | grep $PID >/dev/null || exit 1
 
 echo "  connecting again, with a delay..."
 ../testclient localhost:9901 utah 5 > log &
@@ -41,8 +41,7 @@ kill  $PID
 sleep 1
 
 echo "  checking that the server is dead..."
-ps -p $PID >/dev/null && exit 1
+ps -p $PID | grep $PID >/dev/null && exit 1
 
-echo ok
 # clean up
 rm -rf reg idx.log srv.log zebrasrv.pid