From 8bd0aa82d6c9d31cad4ff286667ed079b501948f Mon Sep 17 00:00:00 2001 From: Olof hagsand Date: Wed, 16 Jun 2021 14:39:28 +0200 Subject: [PATCH] github actions: debug wait backend/restconf --- test/lib.sh | 14 +++++++------- test/test_augment.sh | 3 +-- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/test/lib.sh b/test/lib.sh index 60ba56c8..182181dd 100755 --- a/test/lib.sh +++ b/test/lib.sh @@ -337,12 +337,12 @@ function wait_backend(){ reply=$(echo "]]>]]>" | $clixon_netconf -qef $cfg 2> /dev/null) let i=0; while [[ $reply != "]]>]]>" | clixon_netconf -qef $cfg 2> /dev/null) -# echo "reply:$reply" + echo "reply:$reply" let i++; -# echo "wait_backend $i" + echo "wait_backend $i" if [ $i -ge $DEMLOOP ]; then err "backend timeout $DEMWAIT seconds" fi @@ -382,18 +382,18 @@ function stop_restconf(){ # Reasons for not working: if you run native is nginx running? # @note assumes port=80 if RCPROTO=http and port=443 if RCPROTO=https function wait_restconf(){ -# echo "curl $CURLOPTS $* $RCPROTO://localhost/restconf" + echo "curl $CURLOPTS $* $RCPROTO://localhost/restconf" hdr=$(curl $CURLOPTS $* $RCPROTO://localhost/restconf 2> /dev/null) -# echo "hdr:\"$hdr\"" + echo "hdr:\"$hdr\"" let i=0; while [[ $hdr != *"200"* ]]; do -# echo "wait_restconf $i" + echo "wait_restconf $i" if [ $i -ge $DEMLOOP ]; then err1 "restconf timeout $DEMWAIT seconds" fi sleep $DEMSLEEP hdr=$(curl $CURLOPTS $* $RCPROTO://localhost/restconf 2> /dev/null) -# echo "hdr:\"$hdr\"" + echo "hdr:\"$hdr\"" let i++; done if [ $valgrindtest -eq 3 ]; then diff --git a/test/test_augment.sh b/test/test_augment.sh index 6db1314b..4d85480f 100755 --- a/test/test_augment.sh +++ b/test/test_augment.sh @@ -198,8 +198,7 @@ if [ $BE -ne 0 ]; then err fi new "start backend -s init -f $cfg" - sudo $clixon_backend -F -D 1 -l e -s init -f $cfg -# start_backend -s init -f $cfg + start_backend -s init -f $cfg -D 1 -l e fi new "wait backend"