sendfile: added timer for client
[p2p-kernel-protocol.git] / test / test.sh
index d36d0fe..90a5458 100755 (executable)
@@ -4,6 +4,7 @@ MODULE_NAME=af_p2pkp
 MODULE_DIR=../module
 CLIENT=client/client
 SERVER=server/server
+FILE=/root/Dropbox/school/p2pkp/test/client/test_file
 IP="127.0.0.1"
 
 LISTENERS_PORTS=(
@@ -15,6 +16,8 @@ LISTENERS_PORTS=(
 #use nc.traditional
 echo 2 | update-alternatives --config nc &> /dev/null
 
+[ -e $FILE ] || exit
+
 #increase tests debugging
 set -x
 
@@ -31,7 +34,7 @@ done
 # wait for netcat to start listening
 sleep 1
 
-$CLIENT $ARGUMENTS
+$CLIENT $FILE $ARGUMENTS
 
 # kill netcat
 for pid in $pids; do