Tests: Clean trace_path after each subtest
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Tue, 3 Apr 2018 20:45:23 +0000 (16:45 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 10 Apr 2018 19:41:37 +0000 (15:41 -0400)
Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
tests/regression/tools/rotation/test_kernel
tests/regression/tools/rotation/test_ust

index 6f85e293041dc83c53d1a78d524d4fcc7b7915e0..143bfe0eab760880e5546290593870394b178dbc 100755 (executable)
@@ -64,7 +64,6 @@ function test_kernel_streaming ()
        diag "Test kernel streaming with session rotation"
        create_lttng_session_uri $SESSION_NAME net://localhost
        rotate_kernel_test "${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*"
-       clean_path $TRACE_PATH
 }
 
 function test_kernel_local ()
@@ -95,7 +94,6 @@ function test_kernel_streaming_timer ()
        start_lttng_tracing_ok $SESSION_NAME
 
        rotate_timer_test "${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*" 0
-       clean_path $TRACE_PATH
 }
 
 plan_tests $NUM_TESTS
@@ -122,6 +120,7 @@ skip $isroot "Root access is needed. Skipping all kernel streaming tests." $NUM_
        do
                SESSION_NAME=$(randstring 16 0)
                ${fct_test}
+               clean_path $TRACE_PATH
        done
 
        rmmod lttng-test
index bb788840c3bca0859b1b5b4c591c8bd335273cd6..08a140d9e3ac76d80a3e52c324ad2a410a0a1295 100755 (executable)
@@ -84,7 +84,6 @@ function test_ust_streaming_uid ()
        enable_ust_lttng_event_ok $SESSION_NAME $EVENT_NAME
 
        rotate_ust_test "${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*" "ust/uid/*/*/" 0
-       clean_path $TRACE_PATH
 }
 
 function test_ust_local_uid ()
@@ -94,7 +93,6 @@ function test_ust_local_uid ()
        enable_ust_lttng_event_ok $SESSION_NAME $EVENT_NAME
 
        rotate_ust_test "${TRACE_PATH}" "ust/uid/*/*/" 0
-       clean_path $TRACE_PATH
 }
 
 function test_ust_streaming_pid ()
@@ -105,7 +103,6 @@ function test_ust_streaming_pid ()
        enable_ust_lttng_event_ok $SESSION_NAME $EVENT_NAME "channel0"
 
        rotate_ust_test "${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*" "ust/pid/*/" 1
-       clean_path $TRACE_PATH
 }
 
 function test_ust_local_pid ()
@@ -116,7 +113,6 @@ function test_ust_local_pid ()
        enable_ust_lttng_event_ok $SESSION_NAME $EVENT_NAME "channel0"
 
        rotate_ust_test "${TRACE_PATH}" "ust/pid/*/" 1
-       clean_path $TRACE_PATH
 }
 
 function test_ust_local_timer_uid ()
@@ -130,7 +126,6 @@ function test_ust_local_timer_uid ()
        $TESTAPP_BIN 0 0 /dev/null 2>&1
 
        rotate_timer_test "${TRACE_PATH}" 0
-       clean_path $TRACE_PATH
 }
 
 function test_ust_streaming_timer_uid ()
@@ -144,7 +139,6 @@ function test_ust_streaming_timer_uid ()
        $TESTAPP_BIN 0 0 /dev/null 2>&1
 
        rotate_timer_test "${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*" 0
-       clean_path $TRACE_PATH
 }
 
 function test_ust_local_timer_pid ()
@@ -159,7 +153,6 @@ function test_ust_local_timer_pid ()
        $TESTAPP_BIN 0 0 /dev/null 2>&1
 
        rotate_timer_test "${TRACE_PATH}" 1
-       clean_path $TRACE_PATH
 }
 
 function test_ust_streaming_timer_pid ()
@@ -174,7 +167,6 @@ function test_ust_streaming_timer_pid ()
        $TESTAPP_BIN 0 0 /dev/null 2>&1
 
        rotate_timer_test "${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*" 1
-       clean_path $TRACE_PATH
 }
 
 function test_incompatible_sessions ()
@@ -208,7 +200,6 @@ function test_incompatible_sessions ()
        start_lttng_tracing_ok $SESSION_NAME
        rotate_session_fail $SESSION_NAME
        destroy_lttng_session_ok $SESSION_NAME
-
 }
 
 plan_tests $NUM_TESTS
@@ -228,6 +219,7 @@ for fct_test in ${tests[@]};
 do
        SESSION_NAME=$(randstring 16 0)
        ${fct_test}
+       clean_path $TRACE_PATH
 done
 
 stop_lttng_sessiond
This page took 0.036541 seconds and 4 git commands to generate.