Skip to content

Commit

Permalink
SharedDummyBackend: Increase test timeout
Browse files Browse the repository at this point in the history
Trying to address one possible aspect of #173, that the parent shell
tester that checks for the child to be terminated did not wait long
enough

Also add a ps output for the process in question if we fail so we might
might get a glance at whether the process is stuck or not
  • Loading branch information
phako committed Sep 22, 2020
1 parent 24b6f92 commit cbdb8b4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/scripts/testSharedDummyBackendPidManagement.sh
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
BGPIDS+=("$!")


MAX_EVAL_CNT=10
MAX_EVAL_CNT=20
TIMEOUT_CNT=0
while [ $TIMEOUT_CNT -lt $MAX_EVAL_CNT ]; do
if ps -p $PID_SURPLUS >/dev/null ; # Process still exists
Expand All @@ -93,7 +93,8 @@
let TIMEOUT_CNT+=1

if [ $TIMEOUT_CNT -eq $MAX_EVAL_CNT ]; then
echo "Testing PID Management of SharedDummyBackend failed. Starting a supernumerous process has not been catched."
echo "Testing PID Management of SharedDummyBackend failed. Starting a supernumerous process has not been caught."
ps -p $PID_SURPLUS ; # Show child status before killing it
kill -s SIGINT $PID_SURPLUS
TEST_RESULT=$(( $TEST_RESULT + 2 ))
fi
Expand Down

0 comments on commit cbdb8b4

Please sign in to comment.