3 # Copyright (C) 2019 Philippe Proulx <pproulx@efficios.com>
4 # Copyright (C) 2019 Francis Deslauriers <francis.deslauriers@efficios.com>
6 # This program is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU General Public License
8 # as published by the Free Software Foundation; only version 2
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 # This test validates that a `src.ctf.fs` component successfully reads
21 # specific CTF traces and creates the expected messages.
23 # Such CTF traces to open either exist (in `tests/ctf-traces/succeed`)
24 # or are generated by this test using local trace generators.
28 if [ "x${BT_TESTS_SRCDIR:-}" != "x" ]; then
29 UTILSSH
="$BT_TESTS_SRCDIR/utils/utils.sh"
31 UTILSSH
="$(dirname "$0")/../../utils/utils.sh"
34 # shellcheck source=../../../utils/utils.sh
37 this_dir_relative
="plugins/flt.lttng-utils.debug-info"
38 this_dir_build
="$BT_TESTS_BUILDDIR/$this_dir_relative"
39 succeed_trace_dir
="$BT_CTF_TRACES_PATH/succeed"
40 expect_dir
="$BT_TESTS_DATADIR/$this_dir_relative"
41 binary_artefact_dir
="$BT_TESTS_DATADIR/$this_dir_relative"
46 "-c" "flt.lttng-utils.debug-info"
47 "-p" "target-prefix=\"$binary_artefact_dir/x86_64-linux-gnu/dwarf_full\""
48 "-c" "sink.text.details"
49 "-p" "with-trace-name=no,with-stream-name=no"
52 bt_diff_cli
"$expect_dir/trace-$name.expect" "/dev/null" \
53 "$succeed_trace_dir/$name" "${local_args[@]}"
54 ok $?
"Trace '$name' gives the expected output"
59 test_debug_info debug-info