#!/bin/sh
#
# All the previous tests use pty's to communicate between
# client and server, server and power controller.
# This one uses sockets.
#
TEST=t48
./vpcd -p 10102 &
sleep 1

# -1 means handle one client connection and exit when it exits
# $TEST.conf file specifies nonstandard port of 10103
$PATH_POWERMAND -c $TEST.conf -f -1 2>/dev/null&  
sleep 1

$PATH_POWERMAN -h localhost:10103 \
    -q -Q t1 -Q t[3-5] >$TEST.out 2>$TEST.err
test $? = 0 || exit 1
wait; wait
diff $TEST.out $TEST.exp >$TEST.diff
