#!/bin/bash
#
-# Copyright (C) - 2014 David Goulet <dgoulet@efficios.com>
+# Copyright (C) 2014 David Goulet <dgoulet@efficios.com>
#
-# 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="Save session(s)"
CURDIR=$(dirname $0)/
TESTDIR=$CURDIR/../../../
-SESSIOND_BIN="lttng-sessiond"
-RELAYD_BIN="lttng-relayd"
-LTTNG_BIN="lttng"
SESSION_NAME="save-42"
CHANNEL_NAME="chan-save"
DIR=$(readlink -f $TESTDIR)
-NUM_TESTS=37
+NUM_TESTS=41
source $TESTDIR/utils/utils.sh
create_lttng_session_ok $SESSION_NAME $TRACE_PATH
enable_ust_lttng_channel_ok $SESSION_NAME $CHANNEL_NAME
enable_ust_lttng_event_ok $SESSION_NAME $EVENT_NAME $CHANNEL_NAME
+ lttng_track_ok "-p 666 -u -s $SESSION_NAME"
lttng_save $SESSION_NAME "-o $TRACE_PATH"
enable_ust_lttng_event_ok $SESSION_NAME-2 $EVENT_NAME $CHANNEL_NAME
enable_ust_lttng_event_ok $SESSION_NAME-3 $EVENT_NAME $CHANNEL_NAME
+ lttng_track_ok "-p 666 -u -s $SESSION_NAME-1"
+ lttng_track_ok "-p 666 -u -s $SESSION_NAME-2"
+ lttng_track_ok "-p 666 -u -s $SESSION_NAME-3"
+
lttng_save "" "-a -o $TRACE_PATH"
is_session_saved $TRACE_PATH $SESSION_NAME-1