3 out=`mktemp /tmp/test-gnunet-arm-logXXXXXXXX`
4 tempcfg=`mktemp /tmp/test_dht_api_peer1.XXXXXXXX`
6 armexe="gnunet-arm -c $tempcfg "
7 putexe="gnunet-dht-put -c $tempcfg "
8 getexe="gnunet-dht-get -c $tempcfg "
12 if ! $armexe $DEBUG -e -d > $out ; then
13 echo "FAIL: error running $armexe"
14 echo "Command output was:"
20 cp test_dht_api_peer1.conf $tempcfg
22 echo -n "TEST: Starting ARM..."
23 if ! $armexe $DEBUG -s > $out ; then
24 echo "FAIL: error running $armexe"
25 echo "Command output was:"
33 echo -n "TEST: Testing put..."
34 if ! $putexe -k testkey -d testdata > $out ; then
35 echo "FAIL: error running $putexe"
36 echo "Command output was:"
44 echo -n "TEST: Testing get..."
45 echo "Result 0, type 0:" > $checkout
46 echo "testdata" >> $checkout
48 if ! $getexe -k testkey -T 1 > $out ; then
49 echo "FAIL: error running $putexe"
50 echo "Command output was:"
55 if ! diff -q $out $checkout ; then
56 echo "FAIL: $out and $checkout differ"