/tests/plugins/test_bin_info
/tests/plugins/test_dwarf_complete
/tests/plugins/test_dwarf
+/tests/utils/common.sh
*.o
*.a
*.la
tests/lib/Makefile
tests/lib/writer/Makefile
tests/lib/test-plugin-plugins/Makefile
+ tests/utils/common.sh
tests/utils/Makefile
tests/utils/tap/Makefile
tests/bindings/Makefile
AC_CONFIG_FILES([tests/plugins/test_bin_info_complete], [chmod +x tests/plugins/test_bin_info_complete])
AS_IF([test "x$enable_python_bindings_tests" = xyes],
- [AC_CONFIG_FILES([tests/bindings/python/bt2/testall.sh], [chmod +x tests/bindings/python/bt2/testall.sh])]
+ [AC_CONFIG_FILES([tests/bindings/python/bt2/test_python_bt2], [chmod +x tests/bindings/python/bt2/test_python_bt2])]
)
AS_IF([test "x$enable_python_plugins" = "xyes"],
htmlcov
.coverage
-testall.sh
+test_python_bt2
-check_SCRIPTS = testall.sh
EXTRA_DIST = \
- $(check_SCRIPTS) \
test_clock_class.py \
test_clock_class_priority_map.py \
test_component.py \
LOG_DRIVER = env AM_TAP_AWK='$(AWK)' $(SHELL) $(top_srcdir)/config/tap-driver.sh
if ENABLE_PYTHON_BINDINGS
-TESTS = testall.sh
+TESTS = test_python_bt2
endif
--- /dev/null
+#!/bin/bash
+#
+# Copyright (C) 2017 - Philippe Proulx <pproulx@efficios.com>
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; only version 2
+# of the License.
+#
+# This program 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 General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+NO_SH_TAP=1
+. "@abs_top_builddir@/tests/utils/common.sh"
+
+check_coverage() {
+ coverage run "$@"
+}
+
+export BABELTRACE_PYTHON_BT2_NO_TRACEBACK=1
+export TEST_PLUGIN_PLUGINS_PATH="${BT_BUILD_PATH}/plugins"
+export BABELTRACE_PLUGIN_PATH="${BT_BUILD_PATH}/plugins/ctf:${BT_BUILD_PATH}/plugins/utils:${BT_BUILD_PATH}/plugins/text"
+PYTHON_BUILD_DIR="${BT_BUILD_PATH}/bindings/python"
+BT2_NATIVE_LIBS_DIR="${BT_BUILD_PATH}/bindings/python/bt2/.libs"
+TESTS_UTILS_PYTHON_DIR="${BT_SRC_PATH}/tests/utils/python"
+TESTRUNNER_PY="${BT_SRC_PATH}/tests/utils/python/testrunner.py"
+THIS_DIR="${BT_SRC_PATH}/tests/bindings/python/bt2"
+
+if test "x$TESTALL_COVERAGE" = "x1"; then
+ EXEC=check_coverage
+else
+ EXEC="@PYTHON@"
+
+fi
+
+PYTHONPATH="$PYTHON_BUILD_DIR:$BT2_NATIVE_LIBS_DIR:$TESTS_UTILS_PYTHON_DIR" \
+ "$EXEC" "$TESTRUNNER_PY" "$THIS_DIR"
+res=$?
+
+if test "x$TESTALL_COVERAGE_REPORT" = "x1"; then
+ coverage report -m
+fi
+
+if test "x$TESTALL_COVERAGE_HTML" = "x1"; then
+ coverage html
+fi
+
+exit $res
+++ /dev/null
-#!/bin/sh
-
-check_coverage() {
- coverage run $@
-}
-
-export BABELTRACE_PYTHON_BT2_NO_TRACEBACK=1
-export TEST_PLUGIN_PLUGINS_PATH="@abs_top_builddir@/plugins"
-export BABELTRACE_PLUGIN_PATH="@abs_top_builddir@/plugins/ctf:@abs_top_builddir@/plugins/utils:@abs_top_builddir@/plugins/text"
-PYTHON_BUILD_DIR="@abs_top_builddir@/bindings/python"
-BT2_NATIVE_LIBS_DIR="@abs_top_builddir@/bindings/python/bt2/.libs"
-TESTS_UTILS_PYTHON_DIR="@abs_top_srcdir@/tests/utils/python"
-TESTRUNNER_PY="@abs_top_srcdir@/tests/utils/python/testrunner.py"
-THIS_DIR="@abs_top_srcdir@/tests/bindings/python/bt2"
-
-if test "x$TESTALL_COVERAGE" = "x1"; then
- EXEC=check_coverage
-else
- EXEC="@PYTHON@"
-
-fi
-
-PYTHONPATH="$PYTHON_BUILD_DIR:$BT2_NATIVE_LIBS_DIR:$TESTS_UTILS_PYTHON_DIR" \
- "$EXEC" "$TESTRUNNER_PY" "$THIS_DIR"
-res=$?
-
-if test "x$TESTALL_COVERAGE_REPORT" = "x1"; then
- coverage report -m
-fi
-
-if test "x$TESTALL_COVERAGE_HTML" = "x1"; then
- coverage html
-fi
-
-exit $res
# this program; if not, write to the Free Software Foundation, Inc., 51
# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-TESTDIR=@abs_top_srcdir@/tests
-
-BABELTRACE_BIN=@abs_top_builddir@/cli/babeltrace
-CTF_TRACES=@abs_top_srcdir@/tests/ctf-traces
-
-source $TESTDIR/utils/tap/tap.sh
+. "@abs_top_builddir@/tests/utils/common.sh"
NUM_TESTS=10
plan_tests $NUM_TESTS
test_intersect() {
- trace=$1
- totalevents=$2
- intersect=$3
+ trace="$1"
+ totalevents="$2"
+ intersect="$3"
- test $($BABELTRACE_BIN $trace | wc -l) = $totalevents
+ test "$("${BT_BIN}" "$trace" | wc -l)" = "$totalevents"
ok $? "$totalevents events in the whole trace"
- test $($BABELTRACE_BIN --stream-intersection $trace 2>/dev/null| wc -l) = $intersect
+ test "$("${BT_BIN}" --stream-intersection "$trace" 2>/dev/null| wc -l)" = "$intersect"
ok $? "$intersect events in packets intersecting"
}
diag "Test the stream intersection feature"
diag "2 streams offsetted with 3 packets intersecting"
-test_intersect ${CTF_TRACES}/intersection/3eventsintersect 8 3
+test_intersect "${BT_CTF_TRACES}/intersection/3eventsintersect" 8 3
diag "2 streams offsetted with 3 packets intersecting (exchanged file names)"
-test_intersect ${CTF_TRACES}/intersection/3eventsintersectreverse 8 3
+test_intersect "${BT_CTF_TRACES}/intersection/3eventsintersectreverse" 8 3
diag "No intersection between 2 streams"
-test_intersect ${CTF_TRACES}/intersection/nointersect 6 0
+test_intersect "${BT_CTF_TRACES}/intersection/nointersect" 6 0
diag "Only 1 stream"
-test_intersect ${CTF_TRACES}/intersection/onestream 3 3
+test_intersect "${BT_CTF_TRACES}/intersection/onestream" 3 3
diag "No stream at all"
-test_intersect ${CTF_TRACES}/intersection/nostream 0 0
+test_intersect "${BT_CTF_TRACES}/intersection/nostream" 0 0
-#!/usr/bin/env bash
+#!/bin/bash
#
# Copyright (C) - 2017 Philippe Proulx <pproulx@efficios.com>
#
# this program; if not, write to the Free Software Foundation, Inc., 51
# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-curdir="$(dirname $0)"
-testdir="$curdir/.."
-babeltrace_bin="$curdir/../../cli/babeltrace"
-
-source $testdir/utils/tap/tap.sh
+. "@abs_top_builddir@/tests/utils/common.sh"
test_bt_convert_run_args() {
local what="$1"
local expected_run_args="$3"
# execute convert command
- local run_args="$("$babeltrace_bin" convert --run-args $convert_args)"
+ local run_args="$("$BT_BIN" convert --run-args $convert_args)"
# check result
if [ "$test_head_comment" = 1 ]; then
comment "convert args: $convert_args"
fi
- if [ "$run_args" == "$expected_run_args" ]; then
+ if [ "$run_args" = "$expected_run_args" ]; then
pass "ARGS: $what"
else
fail "ARGS: $what"
local convert_args="$2"
# execute convert command
- "$babeltrace_bin" convert --run-args $convert_args &> /dev/null
+ "$BT_BIN" convert --run-args $convert_args >/dev/null 2>&1
local status=$?
comment "convert args: $convert_args"
fi
- if [ $status == 0 ]; then
+ if [ "$status" = 0 ]; then
fail "SUCCEEDS (should fail): $what"
diag "ARGS: $convert_args"
else
# this program; if not, write to the Free Software Foundation, Inc., 51
# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-CURDIR=$(dirname $0)
-TESTDIR=$CURDIR/..
+. "@abs_top_builddir@/tests/utils/common.sh"
-BABELTRACE_BIN=@abs_top_builddir@/cli/babeltrace
-
-BT_TREE_PATH=@abs_top_srcdir@/
-DEBUG_INFO_TRACE=${BT_TREE_PATH}/tests/debug-info-data/trace/
-
-source $TESTDIR/utils/tap/tap.sh
+DEBUG_INFO_TRACE="${BT_SRC_PATH}/tests/debug-info-data/trace/"
NUM_TESTS=1
plan_tests $NUM_TESTS
-$BABELTRACE_BIN --debug-info-target-prefix ${BT_TREE_PATH} ${DEBUG_INFO_TRACE} 2>/dev/null \
+"${BT_BIN}" --debug-info-target-prefix "${BT_SRC_PATH}" "${DEBUG_INFO_TRACE}" 2>/dev/null \
| @GREP@ 'debug_info = { bin = "libhello_so+0x15a6", func = "bar+0xa9", src = "libhello.c:13" }' >/dev/null
ok $? "Extract debug information"
+++ /dev/null
-#!/bin/bash
-#
-# Copyright (C) - 2016 Nathan Lynch <nathan_lynch@mentor.com>
-#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License, version 2 only, as
-# published by the Free Software Foundation.
-#
-# This program 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 General Public License for
-# more details.
-#
-# You should have received a copy of the GNU General Public License along with
-# this program; if not, write to the Free Software Foundation, Inc., 51
-# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-
-CURDIR=$(dirname $0)
-TESTDIR=$CURDIR/..
-
-BABELTRACE_BIN=$CURDIR/../../cli/babeltrace
-
-source $TESTDIR/utils/tap/tap.sh
-
-expected_formats=(text lttng-live dummy ctf-metadata ctf)
-
-plan_tests ${#expected_formats[*]}
-
-for format in "${expected_formats[@]}"; do
- "$BABELTRACE_BIN" --list | @GREP@ -qw "$format"
- ok $? "Detect support for format \"$format\""
-done
# this program; if not, write to the Free Software Foundation, Inc., 51
# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-CURDIR=$(dirname $0)
-TESTDIR=$CURDIR/..
-
-BABELTRACE_BIN=$CURDIR/../../cli/babeltrace
-CTF_TRACES=@abs_top_srcdir@/tests/ctf-traces
-
-source $TESTDIR/utils/tap/tap.sh
+. "@abs_top_builddir@/tests/utils/common.sh"
NUM_TESTS=10
test_no_lost() {
trace=$1
- $BABELTRACE_BIN $trace >/dev/null 2>&1
+ "${BT_BIN}" "$trace" >/dev/null 2>&1
ok $? "Trace parses"
- $BABELTRACE_BIN $trace 2>&1 >/dev/null | @GREP@ "\[warning\] Tracer lost"
+ "${BT_BIN}" "$trace" 2>&1 >/dev/null | @GREP@ "\[warning\] Tracer lost"
if test $? = 0; then
fail 1 "Should not find any lost events"
else
trace=$1
expectedcountstr=$2
- $BABELTRACE_BIN $trace >/dev/null 2>&1
+ "${BT_BIN}" "$trace" >/dev/null 2>&1
ok $? "Trace parses"
# Convert warnings like:
# WARNING: Tracer discarded 2 trace packets between ....
# WARNING: Tracer discarded 3 trace packets between ....
# into "2,3" and make sure it matches the expected result
- $BABELTRACE_BIN $trace 2>&1 >/dev/null | @GREP@ "WARNING: Tracer discarded" \
+ "${BT_BIN}" "$trace" 2>&1 >/dev/null | @GREP@ "WARNING: Tracer discarded" \
| cut -d" " -f4 | tr "\n" "," | @SED@ "s/.$//" | \
@GREP@ "$expectedcountstr" >/dev/null
ok $? "Lost events string matches $expectedcountstr"
diag "Test the packet_seq_num validation"
diag "No packet lost"
-test_no_lost ${CTF_TRACES}/packet_seq_num/no_lost
+test_no_lost "${BT_CTF_TRACES}/packet_seq_num/no_lost"
diag "No packet lost, packet_seq_num not starting at 0"
-test_no_lost ${CTF_TRACES}/packet_seq_num/no_lost_not_starting_at_0
+test_no_lost "${BT_CTF_TRACES}/packet_seq_num/no_lost_not_starting_at_0"
diag "1 stream, 2 packets lost before the last packet"
-test_lost ${CTF_TRACES}/packet_seq_num/2_lost_before_last "2"
+test_lost "${BT_CTF_TRACES}/packet_seq_num/2_lost_before_last" "2"
diag "2 streams, packets lost in one of them"
-test_lost ${CTF_TRACES}/packet_seq_num/2_streams_lost_in_1 "2"
+test_lost "${BT_CTF_TRACES}/packet_seq_num/2_streams_lost_in_1" "2"
diag "2 streams, packets lost in both"
-test_lost ${CTF_TRACES}/packet_seq_num/2_streams_lost_in_2 "3,2,1"
+test_lost "${BT_CTF_TRACES}/packet_seq_num/2_streams_lost_in_2" "3,2,1"
# this program; if not, write to the Free Software Foundation, Inc., 51
# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-BABELTRACE_BIN=@abs_top_builddir@/cli/babeltrace
+. "@abs_top_srcdir@/tests/utils/common.sh"
-CTF_TRACES=@abs_top_srcdir@/tests/ctf-traces
-
-source @abs_top_srcdir@/tests/utils/tap/tap.sh
-
-SUCCESS_TRACES=(${CTF_TRACES}/succeed/*)
-FAIL_TRACES=(${CTF_TRACES}/fail/*)
+SUCCESS_TRACES=(${BT_CTF_TRACES}/succeed/*)
# -2 because there is an empty trace that we skip
NUM_TESTS=$((${#SUCCESS_TRACES[@]} * 3 - 2))
plan_tests $NUM_TESTS
-for path in ${SUCCESS_TRACES[@]}; do
- out_path=$(mktemp -d)
- text_output1=$(mktemp)
- text_output2=$(mktemp)
- trace=$(basename ${path})
-
- $BABELTRACE_BIN ${path} 2>/dev/null >${text_output1}
- cnt=$(cat ${text_output1} | wc -l)
- if test $cnt == 0; then
- ok 0 "Empty trace, nothing to copy"
+for path in "${SUCCESS_TRACES[@]}"; do
+ out_path="$(mktemp -d)"
+ text_output1="$(mktemp)"
+ text_output2="$(mktemp)"
+ trace="$(basename "${path}")"
+
+ "${BT_BIN}" "${path}" 2>/dev/null >"${text_output1}"
+ ret=$?
+ cnt="$(wc -l < "${text_output1}")"
+ if test "$ret" == 0 && test "$cnt" == 0; then
+ pass "Empty trace, nothing to copy"
continue
fi
- $BABELTRACE_BIN ${path} --component sink.ctf.fs --path ${out_path} >/dev/null 2>&1
+ "${BT_BIN}" "${path}" --component sink.ctf.fs --path "${out_path}" >/dev/null 2>&1
ok $? "Copy trace ${trace} with ctf-fs sink"
- $BABELTRACE_BIN ${out_path} >/dev/null 2>&1
+ "${BT_BIN}" "${out_path}" >/dev/null 2>&1
if test $? != 0; then
fail "Read the new trace in ${out_path}"
continue
fi
- ok 0 "Read the new trace in ${out_path}"
+ pass "Read the new trace in ${out_path}"
- $BABELTRACE_BIN ${out_path} 2>/dev/null >${text_output2}
- cnt=$(diff ${text_output1} ${text_output2} | wc -l)
- test $? == 0
+ "${BT_BIN}" "${out_path}" 2>/dev/null >"${text_output2}"
+ cnt=$(diff "${text_output1}" "${text_output2}" | wc -l)
+ test "$cnt" == 0
ok $? "Exact same content between the two traces"
- rm -rf ${out_path} ${text_output} ${text_output2}
+ rm -rf "${out_path}" "${text_output1}" "${text_output2}"
done
# this program; if not, write to the Free Software Foundation, Inc., 51
# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-CURDIR=$(dirname $0)
-TESTDIR=$CURDIR/..
+. "@abs_top_builddir@/tests/utils/common.sh"
-BABELTRACE_BIN=$CURDIR/../../cli/babeltrace
-
-CTF_TRACES=@abs_top_srcdir@/tests/ctf-traces
-
-source $TESTDIR/utils/tap/tap.sh
-
-SUCCESS_TRACES=(${CTF_TRACES}/succeed/*)
-FAIL_TRACES=(${CTF_TRACES}/fail/*)
+SUCCESS_TRACES=(${BT_CTF_TRACES}/succeed/*)
+FAIL_TRACES=(${BT_CTF_TRACES}/fail/*)
NUM_TESTS=$((${#SUCCESS_TRACES[@]} + ${#FAIL_TRACES[@]}))
plan_tests $NUM_TESTS
-for path in ${SUCCESS_TRACES[@]}; do
- trace=$(basename ${path})
- $BABELTRACE_BIN ${path} > /dev/null 2>&1
+for path in "${SUCCESS_TRACES[@]}"; do
+ trace=$(basename "${path}")
+ "${BT_BIN}" "${path}" > /dev/null 2>&1
ok $? "Run babeltrace with trace ${trace}"
done
-for path in ${FAIL_TRACES[@]}; do
- trace=$(basename ${path})
- $BABELTRACE_BIN ${path} > /dev/null 2>&1
+for path in "${FAIL_TRACES[@]}"; do
+ trace=$(basename "${path}")
+ "${BT_BIN}" "${path}" > /dev/null 2>&1
if [ $? -eq 0 ]; then
fail "Run babeltrace with invalid trace ${trace}"
else
# this program; if not, write to the Free Software Foundation, Inc., 51
# Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-BABELTRACE_BIN=@abs_top_builddir@/cli/babeltrace
+. "@abs_top_srcdir@/tests/utils/common.sh"
-TRACE_PATH=@abs_top_srcdir@/tests/ctf-traces/succeed/wk-heartbeat-u/
-
-source @abs_top_srcdir@/tests/utils/tap/tap.sh
+TRACE_PATH="${BT_CTF_TRACES}/succeed/wk-heartbeat-u/"
NUM_TESTS=10
tmp_out=$(mktemp)
-$BABELTRACE_BIN --clock-gmt --begin 17:48:17.587029529 --end 17:48:17.588680018 \
- ${TRACE_PATH} >/dev/null 2>&1
+"${BT_BIN}" --clock-gmt --begin 17:48:17.587029529 --end 17:48:17.588680018 \
+ "${TRACE_PATH}" >/dev/null 2>&1
ok $? "Read the trace with the trimmer enabled"
-$BABELTRACE_BIN --clock-gmt --begin 17:48:17.587029529 ${TRACE_PATH} \
- 2>/dev/null >${tmp_out}
+"${BT_BIN}" --clock-gmt --begin 17:48:17.587029529 "${TRACE_PATH}" \
+ 2>/dev/null >"${tmp_out}"
ok $? "Running with --begin"
-cnt=$(cat ${tmp_out} | wc -l)
-test $cnt == 18
+cnt=$(wc -l < "${tmp_out}")
+test "$cnt" == 18
ok $? "Expected number of events after trimming begin and end"
-$BABELTRACE_BIN --clock-gmt --end 17:48:17.588680018 ${TRACE_PATH} \
- 2>/dev/null >${tmp_out}
+"${BT_BIN}" --clock-gmt --end 17:48:17.588680018 "${TRACE_PATH}" \
+ 2>/dev/null >"${tmp_out}"
ok $? "Running with --end"
-cnt=$(cat ${tmp_out} | wc -l)
-test $cnt == 9
+cnt=$(wc -l < "${tmp_out}")
+test "$cnt" == 9
ok $? "Expected number of events after trimming end"
-$BABELTRACE_BIN --clock-gmt --begin 17:48:17.587029529 --end 17:48:17.588680018 \
- ${TRACE_PATH} 2>/dev/null >${tmp_out}
+"${BT_BIN}" --clock-gmt --begin 17:48:17.587029529 --end 17:48:17.588680018 \
+ "${TRACE_PATH}" 2>/dev/null >"${tmp_out}"
ok $? "Running with --begin and --end"
-cnt=$(cat ${tmp_out} | wc -l)
-test $cnt == 7
+cnt=$(wc -l < "${tmp_out}")
+test "$cnt" == 7
ok $? "Expected number of events after trimming begin and end"
-$BABELTRACE_BIN --clock-gmt --begin 18:48:17.587029529 ${TRACE_PATH} \
- 2>/dev/null >${tmp_out}
+"${BT_BIN}" --clock-gmt --begin 18:48:17.587029529 "${TRACE_PATH}" \
+ 2>/dev/null >"${tmp_out}"
ok $? "Running with --begin out of range"
-cnt=$(cat ${tmp_out} | wc -l)
-test $cnt == 0
+cnt=$(wc -l < "${tmp_out}")
+test "$cnt" == 0
ok $? "No event output when begin is after the end of the trace"
-$BABELTRACE_BIN --clock-gmt --end 16:48:17.588680018 ${TRACE_PATH} \
- 2>/dev/null >${tmp_out}
-cnt=$(cat ${tmp_out} | wc -l)
-test $cnt == 0
+"${BT_BIN}" --clock-gmt --end 16:48:17.588680018 "${TRACE_PATH}" \
+ 2>/dev/null >"${tmp_out}"
+cnt=$(wc -l < "${tmp_out}")
+test "$cnt" == 0
ok $? "No event output when end is before the beginning of the trace"
-rm ${tmp_out}
+rm "${tmp_out}"
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-BTBIN="@abs_top_builddir@/cli/babeltrace"
+NO_SH_TAP=1
+. "@abs_top_builddir@/tests/utils/common.sh"
-"@abs_top_builddir@/tests/lib/test_ctf_writer" "$BTBIN"
+script="$(readlink -f "$0")"
+curdir="$(dirname "$script")"
+
+"${curdir}/test_ctf_writer" "$BT_BIN"
-#!/bin/sh
+#!/bin/bash
#
# Copyright (C) 2017 Philippe Proulx <pproulx@efficios.com>
#
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-PLUGIN_DIR="@abs_top_builddir@/tests/lib/test-plugin-plugins/.libs"
+NO_SH_TAP=1
+. "@abs_top_builddir@/tests/utils/common.sh"
-"@abs_top_builddir@/tests/lib/test_plugin" "$PLUGIN_DIR"
+script="$(readlink -f "$0")"
+curdir="$(dirname "$script")"
+
+plugin_dir="${curdir}/test-plugin-plugins/.libs"
+
+"${curdir}/test_plugin" "$plugin_dir"
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-PLUGIN_DIR="@abs_top_builddir@/plugins/utils"
+NO_SH_TAP=1
+. "@abs_top_builddir@/tests/utils/common.sh"
-BABELTRACE_PLUGIN_PATH="$PLUGIN_DIR" '@abs_top_builddir@/tests/plugins/test-utils-muxer'
+script="$(readlink -f "$0")"
+curdir="$(dirname "$script")"
+
+plugin_dir="${BT_BUILD_PATH}/plugins/utils"
+
+BABELTRACE_PLUGIN_PATH="$plugin_dir" "${curdir}/test-utils-muxer"
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-DEBUG_INFO_DATA="@abs_top_srcdir@/tests/debug-info-data"
+NO_SH_TAP=1
+. "@abs_top_builddir@/tests/utils/common.sh"
-"@abs_top_builddir@/tests/lib/test_bin_info" "$DEBUG_INFO_DATA"
+script="$(readlink -f "$0")"
+curdir="$(dirname "$script")"
+
+debug_info_data="${BT_SRC_PATH}/tests/debug-info-data"
+
+"${curdir}/test_bin_info" "$debug_info_data"
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-DEBUG_INFO_DATA="@abs_top_srcdir@/tests/debug-info-data"
+NO_SH_TAP=1
+. "@abs_top_builddir@/tests/utils/common.sh"
-"@abs_top_builddir@/tests/lib/test_dwarf" "$DEBUG_INFO_DATA"
+script="$(readlink -f "$0")"
+curdir="$(dirname "$script")"
+
+debug_info_data="${BT_SRC_PATH}/tests/debug-info-data"
+
+"${curdir}/test_dwarf" "$debug_info_data"
--- /dev/null
+#!/bin/sh
+
+BT_SRC_PATH="@abs_top_srcdir@"
+BT_BUILD_PATH="@abs_top_builddir@"
+
+BT_BIN="${BT_BUILD_PATH}/cli/babeltrace@EXEEXT@"
+BT_CTF_TRACES="${BT_SRC_PATH}/tests/ctf-traces"
+
+if [ "x${NO_SH_TAP}" = x ]; then
+ . "${BT_SRC_PATH}/tests/utils/tap/tap.sh"
+fi