From: Jonathan Rajotte Date: Thu, 29 Mar 2018 20:19:39 +0000 (-0400) Subject: Tests: Use SIGTERM instead of SIGKILL X-Git-Tag: v2.11.0-rc1~301 X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=commitdiff_plain;h=e212acd4c2761717696994b4491a288691e5e681 Tests: Use SIGTERM instead of SIGKILL The use of SIGKILL does not guarantee the immediate termination of sub background task. Using SIGTERM allows the generator to finish cleanly. Signed-off-by: Jonathan Rajotte Signed-off-by: Jérémie Galarneau --- diff --git a/tests/regression/tools/notification/test_notification_multi_app b/tests/regression/tools/notification/test_notification_multi_app index 0a05ea6a0..eca9688cf 100755 --- a/tests/regression/tools/notification/test_notification_multi_app +++ b/tests/regression/tools/notification/test_notification_multi_app @@ -315,7 +315,7 @@ function test_multi_app_ust () test_multi_app ust $generator_pid - kill -9 $generator_pid 2> /dev/null + kill -s SIGTERM $generator_pid 2> /dev/null wait $generator_pid 2> /dev/null rm -rf ${TESTAPP_STATE_FILE} 2> /dev/null } @@ -331,7 +331,7 @@ function test_multi_app_kernel () test_multi_app kernel $generator_pid - kill -9 $generator_pid 2>/dev/null + kill -s SIGTERM $generator_pid 2> /dev/null wait $generator_pid 2> /dev/null rm -rf ${TESTAPP_STATE_FILE} 2> /dev/null @@ -348,7 +348,7 @@ function test_on_register_evaluation_ust () test_on_register_evaluation ust $generator_pid - kill -9 $generator_pid 2> /dev/null + kill -s SIGTERM $generator_pid 2> /dev/null wait $generator_pid 2> /dev/null rm -rf ${TESTAPP_STATE_FILE} 2> /dev/null @@ -366,7 +366,7 @@ function test_on_register_evaluation_kernel() test_on_register_evaluation kernel $generator_pid - kill -9 $generator_pid 2> /dev/null + kill -s SIGTERM $generator_pid 2> /dev/null wait $generator_pid 2> /dev/null rm -rf ${TESTAPP_STATE_FILE} 2> /dev/null @@ -458,7 +458,7 @@ function test_on_register_evaluation () destroy_lttng_session_ok $SESSION_NAME stop_lttng_sessiond - kill -9 $generator_pid + kill -s SIGTERM $generator_pid 2> /dev/null wait $generator_pid 2> /dev/null for pipe in "${consumerd_pipe[@]}"; do