From c291bea80bd9a7320b1ee6b966d15abcea3d2d48 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Sun, 26 Jun 2022 16:25:41 +0200 Subject: fix #7228: make it easy to test hanging providers --- src/testing/test_prepare.sh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/testing/test_prepare.sh b/src/testing/test_prepare.sh index 2c9191c..202342d 100755 --- a/src/testing/test_prepare.sh +++ b/src/testing/test_prepare.sh @@ -22,6 +22,7 @@ function cleanup() { for n in `jobs -p` do + kill -SIGCONT $n # in case one provider was suspended kill $n 2> /dev/null || true done rm -rf $CONF $CONF_4 $WALLET_DB $R1FILE $R2FILE $B1FILE $B2FILE $TMP_DIR @@ -394,10 +395,17 @@ echo -n "Launching anastasis services ..." # PREFIX="valgrind --log-file=anastasis-httpd.%p.log" PREFIX="" $PREFIX anastasis-httpd -L INFO -c $CONF_1 2> anastasis-httpd_1.log & +PPID_1=$! $PREFIX anastasis-httpd -L INFO -c $CONF_2 2> anastasis-httpd_2.log & +PPID_2=$! $PREFIX anastasis-httpd -L INFO -c $CONF_3 2> anastasis-httpd_3.log & +PPID_3=$! $PREFIX anastasis-httpd -L INFO -c $CONF_4 2> anastasis-httpd_4.log & - +PPID_4=$! +export PPID_1 +export PPID_2 +export PPID_3 +export PPID_4 if test $1 = 'fees' then @@ -548,6 +556,8 @@ then export WALLET_DB fi +echo '- use kill -SIGSTOP $PPID_$NUM ($NUM: 1-4) to suspend providers' + bash exit 0 -- cgit v1.2.3