X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=tests%2Fregression%2Ftools%2Frelayd-grouping%2Ftest_ust;h=64fb90e348d25203816f0e90cd506e5d5dbfbea9;hb=d11e3c3eeec8ba7db67f3b96c09fca4b7cabc9ad;hp=85d7197e6633e562d52e9139d8d3eb212aff87cc;hpb=6c4a91d639747f260ab46decebc50998ef063712;p=lttng-tools.git diff --git a/tests/regression/tools/relayd-grouping/test_ust b/tests/regression/tools/relayd-grouping/test_ust index 85d7197e6..64fb90e34 100755 --- a/tests/regression/tools/relayd-grouping/test_ust +++ b/tests/regression/tools/relayd-grouping/test_ust @@ -1,19 +1,8 @@ #!/bin/bash # -# Copyright (C) - 2018 Jonathan Rajotte +# Copyright (C) 2018 Jonathan Rajotte # -# This library is free software; you can redistribute it and/or modify it under -# the terms of the GNU Lesser General Public License as published by the Free -# Software Foundation; version 2.1 of the License. -# -# This library is distributed in the hope that it will be useful, but WITHOUT -# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -# FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more -# details. -# -# You should have received a copy of the GNU Lesser General Public License -# along with this library; if not, write to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +# SPDX-License-Identifier: LGPL-2.1-only TEST_DESC="LTTng relayd filesystem grouping - Userspace tracing" @@ -27,10 +16,10 @@ TESTAPP_BIN="$TESTAPP_PATH/$TESTAPP_NAME/$TESTAPP_NAME" EVENT_NAME="tp:tptest" CHANNEL_NAME="my_channel" -XSD_PATH=$TESTDIR/../src/common/mi-lttng-3.0.xsd +XSD_PATH=$TESTDIR/../src/common/mi-lttng-4.0.xsd -XML_VALIDATE="$TESTDIR/regression/tools/mi/validate_xml $XSD_PATH" -XML_EXTRACT="$TESTDIR/regression/tools/mi/extract_xml" +XML_VALIDATE="$TESTDIR/utils/xml-utils/validate_xml $XSD_PATH" +XML_EXTRACT="$TESTDIR/utils/xml-utils/extract_xml" XPATH_CMD_OUTPUT="//lttng:command/lttng:output" XPATH_SESSION="$XPATH_CMD_OUTPUT/lttng:sessions/lttng:session" @@ -51,7 +40,7 @@ function get_auto_session_name () local lttng_bin=$LTTNG_BIN LTTNG_BIN="${lttng_bin} --mi xml" - OUTPUT_DEST=$(mktemp) + OUTPUT_DEST=$(mktemp --tmpdir "tmp.${FUNCNAME[0]}_output.XXXXXX") list_lttng_with_opts $XML_VALIDATE "$OUTPUT_DEST" @@ -59,6 +48,7 @@ function get_auto_session_name () value=$($XML_EXTRACT "$OUTPUT_DEST" ${XPATH_SESSION}/lttng:name/text\(\)) ok $? "Extraction of session name" + rm -f $OUTPUT_DEST OUTPUT_DEST=/dev/null LTTNG_BIN=$lttng_bin @@ -473,8 +463,8 @@ function test_ust_pid_streaming_snapshot () local file_sync_after_first local file_sync_before_last - file_sync_after_first=$(mktemp -u) - file_sync_before_last=$(mktemp -u) + file_sync_after_first=$(mktemp --tmpdir -u "tmp.${FUNCNAME[0]}_sync_after_first.XXXXXX") + file_sync_before_last=$(mktemp --tmpdir -u "tmp.${FUNCNAME[0]}_sync_before_last.XXXXXX") if [ -z "$session_name" ]; then is_automatic_session=true @@ -687,7 +677,7 @@ for fct_test in "${tests[@]}"; do for grouping in "${grouping_types[@]}"; do - TRACE_PATH=$(mktemp -d) + TRACE_PATH=$(mktemp --tmpdir -d tmp.test_relayd_grouping_ust_trace_path.XXXXXX) # Set the relayd in --group-output-by-session mode start_lttng_relayd "-o $TRACE_PATH $grouping" start_lttng_sessiond