projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Tests: add notap versions of start/stop tracing helpers
[lttng-tools.git]
/
tests
/
utils
/
utils.sh
diff --git
a/tests/utils/utils.sh
b/tests/utils/utils.sh
index 2d53a7237350e6df4b5492ab2930c0d2f6f391a9..2343b4b28d3e872437072fee95bb00601c300fd2 100644
(file)
--- a/
tests/utils/utils.sh
+++ b/
tests/utils/utils.sh
@@
-1081,54
+1081,76
@@
function disable_python_lttng_event ()
ok $? "Disable Python event $event_name for session $sess_name"
}
ok $? "Disable Python event $event_name for session $sess_name"
}
-function start_lttng_tracing ()
+function start_lttng_tracing
_opt
()
{
{
- local expected_to_fail=$1
- local sess_name=$2
+ local withtap=$1
+ local expected_to_fail=$2
+ local sess_name=$3
$TESTDIR/../src/bin/lttng/$LTTNG_BIN start $sess_name 1> $OUTPUT_DEST 2> $ERROR_OUTPUT_DEST
ret=$?
if [[ $expected_to_fail -eq "1" ]]; then
test "$ret" -ne "0"
$TESTDIR/../src/bin/lttng/$LTTNG_BIN start $sess_name 1> $OUTPUT_DEST 2> $ERROR_OUTPUT_DEST
ret=$?
if [[ $expected_to_fail -eq "1" ]]; then
test "$ret" -ne "0"
- ok $? "Start tracing for session $sess_name failed as expected"
+ ret=$?
+ if [ $withtap -eq "1" ]; then
+ ok $? "Start tracing for session $sess_name failed as expected"
+ fi
else
else
- ok $ret "Start tracing for session $sess_name"
+ if [ $withtap -eq "1" ]; then
+ ok $ret "Start tracing for session $sess_name"
+ fi
fi
}
function start_lttng_tracing_ok ()
{
fi
}
function start_lttng_tracing_ok ()
{
- start_lttng_tracing 0 "$@"
+ start_lttng_tracing
_opt 1
0 "$@"
}
function start_lttng_tracing_fail ()
{
}
function start_lttng_tracing_fail ()
{
- start_lttng_tracing 1 "$@"
+ start_lttng_tracing
_opt 1
1 "$@"
}
}
-function st
op_lttng_tracing
()
+function st
art_lttng_tracing_notap
()
{
{
- local expected_to_fail=$1
- local sess_name=$2
+ start_lttng_tracing_opt 0 1 "$@"
+}
+
+function stop_lttng_tracing_opt ()
+{
+ local withtap=$1
+ local expected_to_fail=$2
+ local sess_name=$3
$TESTDIR/../src/bin/lttng/$LTTNG_BIN stop $sess_name 1> $OUTPUT_DEST 2> $ERROR_OUTPUT_DEST
ret=$?
if [[ $expected_to_fail -eq "1" ]]; then
test "$ret" -ne "0"
$TESTDIR/../src/bin/lttng/$LTTNG_BIN stop $sess_name 1> $OUTPUT_DEST 2> $ERROR_OUTPUT_DEST
ret=$?
if [[ $expected_to_fail -eq "1" ]]; then
test "$ret" -ne "0"
- ok $? "Stop lttng tracing for session $sess_name failed as expected"
+ ret=$?
+ if [ $withtap -eq "1" ]; then
+ ok $? "Stop lttng tracing for session $sess_name failed as expected"
+ fi
else
else
- ok $ret "Stop lttng tracing for session $sess_name"
+ if [ $withtap -eq "1" ]; then
+ ok $ret "Stop lttng tracing for session $sess_name"
+ fi
fi
}
function stop_lttng_tracing_ok ()
{
fi
}
function stop_lttng_tracing_ok ()
{
- stop_lttng_tracing 0 "$@"
+ stop_lttng_tracing
_opt 1
0 "$@"
}
function stop_lttng_tracing_fail ()
{
}
function stop_lttng_tracing_fail ()
{
- stop_lttng_tracing 1 "$@"
+ stop_lttng_tracing_opt 1 1 "$@"
+}
+
+function stop_lttng_tracing_notap ()
+{
+ stop_lttng_tracing_opt 0 0 "$@"
}
function destroy_lttng_session ()
}
function destroy_lttng_session ()
This page took
0.024864 seconds
and
4
git commands to generate.