local local_path="${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*"
local remote_trace_path="${HOSTNAME}/${SESSION_NAME}"
local channel_name="chan"
- local bt_output_path=$(mktemp -d)/bt-output.txt
+ local bt_output_path=$(mktemp -t tmp.test_ust_streaming_live_viewer_bt_output.XXXXXX)
diag "Test ust streaming live clear with viewer"
diag "Parameters: tracing_active=$tracing_active, clear_twice=$clear_twice, buffer_type=$buffer_type"
local local_path="${TRACE_PATH}/${HOSTNAME}/${SESSION_NAME}*"
local remote_trace_path="${HOSTNAME}/${SESSION_NAME}"
local channel_name="chan"
- local bt_output_path
- local bt_error_path
- local file_sync_before_exit
- bt_output_path=$(mktemp -d)/bt-output.txt
- bt_error_path=$(mktemp -d)/bt-output.err
- file_sync_before_exit=$(mktemp -u)
+ local bt_output_path=$(mktemp -t tmp.test_ust_streaming_live_viewer_new_metadata_after_clear_bt_output.XXXXXX)
+ local bt_error_path=$(mktemp -t tmp.test_ust_streaming_live_viewer_new_metadata_after_clear_bt_error.XXXXXX)
+ local file_sync_before_exit=$(mktemp -u -t tmp.test_ust_streaming_live_viewer_new_metadata_after_clear_sync_before_exit.XXXXXX)
diag "Test ust streaming live clear with viewer with new metadata after clear"
diag "Parameters: tracing_active=$tracing_active, clear_twice=$clear_twice, buffer_type=$buffer_type"
clean_path "$bt_output_path"
clean_path "$bt_error_path"
+ rm -f "$file_sync_before_exit"
}
function test_ust_local ()
function test_save_load_mi ()
{
- tmp_xml_output=$(mktemp -u)
- tmp_save_output=$(mktemp -d)
- trace_path=$(mktemp -d)
+ local tmp_xml_output=$(mktemp -u)
+ local tmp_save_output=$(mktemp -d)
+ local trace_path=$(mktemp -d)
diag "Test save/load/list/MI with rotation"
create_lttng_session_ok $SESSION_NAME $trace_path
# save, destroy and reload the same session
OUTPUT_DEST=/dev/null
- lttng_save $SESSION_NAME "-o $tmp_save_output$SESSION_NAME"
+ lttng_save $SESSION_NAME "-o $tmp_save_output/$SESSION_NAME"
destroy_lttng_session_ok $SESSION_NAME
- lttng_load_ok "-i $tmp_save_output$SESSION_NAME"
+ lttng_load_ok "-i $tmp_save_output/$SESSION_NAME"
OUTPUT_DEST=${tmp_xml_output}
# Check the output of lttng list with the 2 rotation parameters after the load
OUTPUT_DEST=/dev/null
destroy_lttng_session_ok $SESSION_NAME
- rm -rf ${trace_path}
- rm $tmp_xml_output
- rm -rf $tmp_save_output
+ rm -rf "$trace_path"
+ rm "$tmp_xml_output"
+ rm -rf "$tmp_save_output"
}
plan_tests $NUM_TESTS