From 5be14856a356b087ad97b479efd9b06172fdfd2f Mon Sep 17 00:00:00 2001 From: Andreas Ebner Date: Sat, 14 Sep 2019 16:58:39 +0200 Subject: Bugfixes, changed test reporting behavior, modified intermediate result reporting: - fixed a memory error when serializing the delegations - all tests now handle the returned error code from the gnunet-credential.c via "ret" variable - intermediate reporting excluded during collect message - intermediate reporting now contains the direction (bw/fw) --- src/credential/test_credential_own.sh | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'src/credential/test_credential_own.sh') diff --git a/src/credential/test_credential_own.sh b/src/credential/test_credential_own.sh index 2bb5cb070..fa2580a22 100755 --- a/src/credential/test_credential_own.sh +++ b/src/credential/test_credential_own.sh @@ -107,9 +107,9 @@ echo "+++ Starting to Resolve +++" DELS=`$DO_TIMEOUT gnunet-credential --collect --issuer=$EPUB_KEY --attribute=$DISC_ATTR --ego=alice --backward -c test_credential_lookup.conf | paste -d, -s` echo $DELS echo gnunet-credential --verify --issuer=$EPUB_KEY --attribute=$DISC_ATTR --subject=$ALICE_KEY --delegate=\'$DELS\' --backward -c test_credential_lookup.conf -RES_DELS=`gnunet-credential --verify --issuer=$EPUB_KEY --attribute=$DISC_ATTR --subject=$ALICE_KEY --delegate="$DELS" --backward -c test_credential_lookup.conf` - +gnunet-credential --verify --issuer=$EPUB_KEY --attribute=$DISC_ATTR --subject=$ALICE_KEY --delegate="$DELS" --backward -c test_credential_lookup.conf +RES=$? # Cleanup properly gnunet-namestore -z epub -d -n $DISC_ATTR -t ATTR -c test_credential_lookup.conf @@ -123,13 +123,11 @@ gnunet-namestore -z stateu -d -n $STATE_STUD_ATTR -t ATTR -c test_credential_loo gnunet-arm -e -c test_credential_lookup.conf -if [ "$RES_DELS" != "Failed." ] +if [ $RES == 0 ] then - # TODO: replace echo -e bashism - echo -e "${RES_DELS}" exit 0 else - echo "FAIL: Failed to verify credential $RES_DELS." + echo "FAIL: Failed to verify credential." exit 1 fi -- cgit v1.2.3